Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

Parsing old MF data files - Record Headers and...
2 questions at the end of this update and setup...

I've downloaded ParseRat and seem to be making progress on getting the data
out of this old COBOL / DOS 6.2 application. The application seems to have
been created with Micro Focus COBOL/2 Version 1.2.29 L2.2 revision 003

According to a previous post by Richard...
The first 128 bytes of the data files are 'file headers' ... and then each
record has a 2 byte 'record header'
- That seems to agree with what I'm seeing.

And Richard said... the if the first 4 bits of the 'record header' are 0100
then it is a 'user record'
- That seems true too as all of the records in Owners.FIL are preceeded with
Hex 41 B7 (1st byte = 41hex and 2nd byte = B7hex)

- If I tell ParseRat that the first 128 bytes are file header... and define
the total record length in bytes... then all fields line up vertically...
all Lname fields, all Fname fields, all Date fields, etc...
- And every record begins with 41hex and B7hex... then the first field
defined in the Copybook file starts.
- Every field seems to match the length defined in the associated copybook
file.

QUESTION 1 - Is it safe to assume that all records who's 1st 4 bits are 0100
are 'user records' that are active and not 'deleted' records? If no how do I
tell?
QUESTION 2 - There is some data tagged on the end of each record... and
often it is just blank... but down the list of records I start seeing... NNI
or MOS or LBE or MAN or NDR or ORA or REG.
Anybody have any idea what this may mean??? Maybe that is telling me the
status of the record? I don't know.

I've actually be able to export the data as comma delimited data... and then
been able to import into Microsoft Access as a new table... I'm ready to do
all the data files but first I want to make sure I'm understanding the file
formats correctly.

Thanks everyone for pitching in here. Very helpful to a guy who has never
done COBOL before. (And I'm sure it shows :)




Report this thread to moderator Post Follow-up to this message
Old Post
Will
12-15-07 11:56 PM


Re: Parsing old MF data files - Record Headers and...
"Will" <Will@somewhere.com> wrote in message
 news:476410e9$0$28874$4c368faf@roadrunne
r.com...
> 2 questions at the end of this update and setup...
[snip]
> QUESTION 1 - Is it safe to assume that all records who's 1st 4 bits are
0100
> are 'user records' that are active and not 'deleted' records? If no how do
I
> tell?

Yes. Deleted records are 0010. Note that 0101 thru 1000 are
also user records or pointers to user records; but I've never
seen them in a file and do not know under what conditions they
are generated. (Possibly for record lengths > 4K)

> QUESTION 2 - There is some data tagged on the end of each record... and
> often it is just blank... but down the list of records I start seeing...
NNI
> or MOS or LBE or MAN or NDR or ORA or REG.
> Anybody have any idea what this may mean??? Maybe that is telling me the
> status of the record? I don't know.

As was mentioned previously, physical data records are a multiple
of 4 bytes in length. 439 (x"01B7") + 2 = 441, 444 is the next multiple.
The three characters are fillers and should be ignored.



Report this thread to moderator Post Follow-up to this message
Old Post
Rick Smith
12-15-07 11:56 PM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

Cobol archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 05:46 AM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.