View previous topic :: View next topic
|
Author |
Message |
Chris Leggett
New User
Joined: 29 Mar 2005 Posts: 1 Location: Liverpool, England
|
|
|
|
I need to compare 2 large files (A and B) and produce a third file (C) containing any records which are on file A but Not on file B.
Files A and B are the same format, as they are tables downloaded from DB2. File C will also be identical format.
I am sure this can be done with DFSort, as it sounds so simple, but am not sure how.
Any help would be gratefully received. Thanks. |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
You can use the SPLICE operator of DFSORT's ICETOOL to do this kind of thing. Exactly how you would do it depends on exactly what you want to do. So you need to supply some more information:
What is the RECFM and LRECL of FileA and FileB? What is the starting position, length and format of the "key" you want to use for the comparison? Or do you want to compare the entire record?
Please show an example of the records in FileA and the records in FileB and the expected output records. If FileA can have duplicates, show that in your example. If FileB can have duplicates, show that in your example. |
|
Back to top |
|
|
die7nadal
Active User
Joined: 23 Mar 2005 Posts: 156
|
|
|
|
Chris Leggett wrote: |
I need to compare 2 large files (A and B) and produce a third file (C) containing any records which are on file A but Not on file B.
Files A and B are the same format, as they are tables downloaded from DB2. File C will also be identical format.
I am sure this can be done with DFSort, as it sounds so simple, but am not sure how.
Any help would be gratefully received. Thanks. |
I am not sure if you can do this through SORT, but you can do it through COMPAREX. Give FILE A in SYSUT2 and FILE B in SYSUT1 and Just define FILE C in SYSUT3 DD and in SYSIN DD try to Differentiate the records that u want in FILE C through the use of some KEY and then give COPYDIFF Key word. If you dont have COMPAREX in your shop, you should be having a equivalent utility for doing Compares. |
|
Back to top |
|
|
|