Posted: Thu Jan 24, 2008 5:50 am Post subject: Files comparing and copy unmatched records to output file
I want to compare two files of different lengths. But both contains a common Id(suppose SSN).
Here i want to compare file2 with file1 and with the common Id(SSN) and if found, i want to omit that record and i want to copy all unmatched records to third output file.
For example:
First file:
ssn
1
2
3
4
5
Second file:
ssn
4
5
Third file:
ssn
1
2
3
Could you please let me know is it possible through syncsort.
If your data is actually more complex than that, show a better example of the records in each input file (relevant fields only) and what you expect for output.
If you're not familiar with DFSORT and DFSORT's ICETOOL, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:
Obviously, you will need to modify the JOINKEYS FIELDS based upon your actual data. Let me know if you require any further assistance. _________________ Alissa Margulies
SyncSort Mainframe Product Services
201-930-8260
zos_tech@syncsort.com
Looks like your data is not in column 1 but rather column 2... Try either moving your data or changing the JOINKEYS FIELDS to reflect (2,1,A). _________________ Alissa Margulies
SyncSort Mainframe Product Services
201-930-8260
zos_tech@syncsort.com
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum