View previous topic :: View next topic
|
Author |
Message |
mohans_472
New User
Joined: 11 Oct 2009 Posts: 4 Location: hyderabad
|
|
|
|
We are required to migrate the system andporting the files from mainframes to unix.
To port a file we have to find the copybook of the file.Presently we are back tracking from jCl and identifying the copybook associated to that file . Depending on the data type (packet decimal,comp etc)we have treat that feild differently.
Process to identify the exact copybook for each file takes time and prone to errors.So to cross verify i want to know if we could confirm from the file if there is any of these feilds in that file without using copybook.
Presently we are using " F ALL P'.' " assuming it will identify whether any packet data is present in the file.
Do we have any procedure or commands to identify the type of data feilds at a high levels. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
GuyC, really worked hard not to be 'aggressive'.
mohans_472,
You can not process the data in the UNIX system
without an accurate description of the records of each file.
which means you have to find the copybooks that contain the record description.
Actually, without the record descriptions, how was the UNIX system developed?
Quote: |
Presently we are using " F ALL P'.' " assuming it will identify whether any packet data is present in the file. |
The ISPF EDIT command - Find ALL P'.' - only provides non-display char,
has nothing to do with PACKED-DECIMAL.
Quote: |
Process to identify the exact copybook for each file takes time and prone to errors. |
why is this an error prone process?
This should be a rather easy exercise -
it is what every consultant does during the first few hours at a new site. |
|
Back to top |
|
|
mtaylor
Active User
Joined: 20 Feb 2009 Posts: 108 Location: Kansas City
|
|
|
|
Quote: |
why is this an error prone process? |
I've spent half a day tracking down one copybook for a file that was read in as a PIC X(80) (for example) then moved to various other copybooks in various subroutines. Maybe that's what the OP means?
But yeah, for the general question 'determine file layout without copybook' there is no solution. I've seen a couple of academic papers and I think there was book about the subject ('data reverse engineering') as well. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
mtaylor,
I understand that garbage coding techniques make it laborious to find definitions,
but 'error prone process'?
maybe that should read 'error prone processors'. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
Quote: |
Do we have any procedure or commands to identify the type of data feilds at a high levels. |
You have a string of 4 bytes that have the values x'0097994D' -- what do they represent? If it is a COMP field, it represents the value 9935181. If it is a COMP-3 field, it represents the value -97994. If it is a DISPLAY field, it represents the value <low value>pr(. And that just assumes the data is EBCDIC -- there are other answers for ASCII.
But without knowing the format of the data in advance, you cannot tell by inspection if the value is 9935181, -97994, or .pr( -- they are all three perfectly valid representations of the same four bytes. |
|
Back to top |
|
|
mohans_472
New User
Joined: 11 Oct 2009 Posts: 4 Location: hyderabad
|
|
|
|
I am sorry for not being clear by saying"prone to error" i mean the manual error that was invovled in the process.
As i said we are porting the files from mainframes to unix and for that we are using a product"DMEXPRESS" from syncsort(similar ti Fileport) .
Dmexpress expects the complete file layout as it treat the packed data,COMP,numeric fields differently.
Presently we have around 2500+ files to be ported but in our inventory the cobol program coding standard is not specific . In copybook it is declared as alphanumeric but some fields of the copybook are getting populated with other types of data by other program called within the main program. Our file lenght are much as 16000 so its taking lot of man hours and analysis and there is always a hesitation if we missed out any feilds is within us.
So for reducing some of our efforts we want to know if the field contains only characters or numeric faulds only(in either case there is no need of layout description to DMEXPRESS).Assuming that these fields will not be having non printable characters we are checking for "F P'.' all'" in the file. |
|
Back to top |
|
|
|