I am new to ICETOOL and trying to get an idea about the SPLICE option. I was going thru some material and came across the below mentioned code. I was little confused with this. Could anybody please explain me the same.
Here it will take 2 input files and create files with matching and non-matching records.
With this job, you copy records from file 1 in a temporary file, and you overlay position 12 and 13 of each records with 2 '1'. You copy file 2 in the same file but you overlay position 12 and 13 with 2 "2"
The splice command copy records FROM input file (T1) TO output file(out12). If the key of the next records is the same (ON(1,1,,CH)), you overlay position 13 of the first records with the content of position 13 from the next record and delete next record(WITH(13,1)). You copy also the records were key is unique in the input file (KEEPNODUPS). Output records are also modified in accordance of the sort instruction contained in dataset represented by ddname CTL3CNTL (USING(CTL3)).
Splice works only with a single input file (may be a concatenation of file of course). You copy the records from 2 separate files in one file and mark them with a label in order to be able to recognize the origin of the records (the 11 for file 1 and the 22 for file 2). With the splice you replace in the records with the same key the second character of the label introduced previously and you keep all records not duplicated with the original label.
In result you will copy only records first records from duplicated records and all non duplicated records. Records from file one not duplicated or duplicated only in file one will have a label of 11. Records not duplicated from file2 or duplicated only in file 2 will have a label of 22. And records from file 1 duplicated in file 2 will have a label of 12.
With the dfsort statement you split your output in 3 files in accordance with the label, and you take only the 10 first position and pad your records with 70 blanks (probably to force FB 80 ).
DFSORT's ICETOOL allow you to do a lot more thing with your data. If you go to the IBM DFSORT site at