F1 -
aaa 123456
bbb 111111
ccc 333333
bbb 111111
ccc 333333
F2 -
bbb 111111
ccc 333333
eee 555555
ccc 333333
eee 555555
I'm referring the below link to perform this
http://www-01.ibm.com/support/knowledge ... ethod_.htm
Am using below code, however am getting same records in both the output files as that of F1. I dont understand why am not getting desired output.
//SORTJNF1 DD DSN=F1,DISP=SHR
//SORTJNF2 DD DSN=F2,DISP=SHR
//F1ONLY DD SYSOUT=*
//BOTH DD DSN=Out-file,
// DISP=(,CATLG,DELETE),
// UNIT=APGGRP,SPACE=(CYL,(1000,1000),RLSE)
//SYSOUT DD SYSOUT=*
//SYSIN DD *
JOINKEYS FILE=F1,FIELDS=(1,3,A)
JOINKEYS FILE=F2,FIELDS=(1,3,A)
JOIN UNPAIRED,F1,F2
REFORMAT FIELDS=(F1:1,10)
OPTION COPY
OUTFIL FNAMES=F1ONLY,BUILD=(1,10)
OUTFIL FNAMES=BOTH,BUILD=(1,10)
//SORTJNF2 DD DSN=F2,DISP=SHR
//F1ONLY DD SYSOUT=*
//BOTH DD DSN=Out-file,
// DISP=(,CATLG,DELETE),
// UNIT=APGGRP,SPACE=(CYL,(1000,1000),RLSE)
//SYSOUT DD SYSOUT=*
//SYSIN DD *
JOINKEYS FILE=F1,FIELDS=(1,3,A)
JOINKEYS FILE=F2,FIELDS=(1,3,A)
JOIN UNPAIRED,F1,F2
REFORMAT FIELDS=(F1:1,10)
OPTION COPY
OUTFIL FNAMES=F1ONLY,BUILD=(1,10)
OUTFIL FNAMES=BOTH,BUILD=(1,10)