parsing key file
Bill Campbell
bill at celestial.com
Tue May 25 11:34:00 PDT 2021
It's been decades since I had to do this. I don't remember the
details of the 40 character header other than the first character
indicates whether the record is active or has been deleted.
Beyond that, the key (and data) records have no delimiter
separating the records, but are fixed length. The key records
are 40 + length of all fields so require reads of explicit
length. In python this might be:
fh = open('pathtokeyfile', 'rb')
n = 20 + reclength
for rec in fh.read(n):
hdr = rec[0:20]
data = rec[20:]
...
On Tue, May 25, 2021, Jose Lerebours via Filepro-list wrote:
>Can anyone tell me what is the BOR or EOR markers?
>
>I could save time if I know exactly what the first 40 or characters are or if
>there is a delimiter/marker I can reference to split the segments.
>
>I put together sa simple script but it turns out that there is more to it
>than I thought - Got to do some coding on some other stuff but I will
>come back to this in a few ... hope you guys have an answer for me by then!
>
>Thanks,
>
>--
>
>https://www.asisuites.com
>https://www.helpsuites.com
>
>_______________________________________________
>Filepro-list mailing list
>Filepro-list at lists.celestial.com
>Subscribe/Unsubscribe/Subscription Changes
>http://mailman.celestial.com/mailman/listinfo/filepro-list
Bill
--
INTERNET: bill at celestial.com Bill Campbell; Celestial Software LLC
URL: http://www2.celestial.com/ 6641 E. Mercer Way
Mobile: (206) 947-5591 PO Box 820
Fax: (206) 232-9186 Mercer Island, WA 98040-0820
More information about the Filepro-list
mailing list