Joined: 10 Dec 2010 Posts: 96 Location: Massachusetts
I have a 10 byte input file of account numbers and an output file of 10 bytes. I need to drop duplicates from the input file, but, I need to keep the dropped records. I thought I could use the SAVE option of OUTFIL that I saw from another post but I cannot get the output for the dropped records without using INCLUDE it seems. I tried the following code but all I get is the records sort keeps and not the ones it drops.
Once you use SUM FIELDS=NONE , your duplicate records are gone by the time OUTFIL processing is done. You need to use SELECT operator with FIRST option. The following DFSORT/ICETOOL JCL will give you the desired results.