Embedded carriage return in PC data
Merol Newman
merol.newman@ramesys.com
Thu, 21 Mar 2002 12:14:01 -0000
Hello Jeff
Blue suggested setting up the file in the dictionary (like the dummy subfile,
but more suitable for a regular job) with a single record the size of the
longest line.
> The record is a variable length, how would I create a PHD file layout to
> match that?
Combining his two suggestions, you could make this a fixed length file,
extending the shorter lines with convert/pad=%x20/fdl= etc. (I think this is for
an ascii file, or pad=%d32 for binary - you probably know more about this than
me!)
You will then be able to read the file in PH.
Is there any feature that identifies the beginning of the Access record? If not,
I give up at this point! But I'm imagining something like
09/03/2002 PR2345 bla bla bla bl
a bla bla 1 Y 23 bla bla bla bla
bla bla bla bla
where you could do
def start-rec cha*10 = bigrecord{1:10]
and test start-rec for being a date, or whatever.
You would also have to be able to identify where the free text ends in the
middle of a line (as above, with "1 Y 23").
If you can do these things, we might be able to do something in qtp, or a quick
"while retrieving" process, to write the contents of several lines of input to
another file with the separate data items. This would be quite a bit of PH code,
so it's not worth going into it any further if not.
When I say "we", I mean we have a program that does something similar.
regards
Merol
merol.newman@ramesys.com
Ramesys, Eldon Way, Crick, Northamptonshire, UK. NN6 7SL
phone 01788 822133/823831, fax 01788 823601