Hi,
I have 2 files with header,detail & trailor records in it.
Let the first file be file 1 be
HDR 1010 20090820 20090820 181007 77000 7010
detail1 0000 aaaaaaaaaaaaaaaaaaaaaaa
detail2 0000 bbbbbbbbbbbbbbbbbbbbbbb
TRL 1010 20090820 20090820 181007 77000 7010 00002
and file 2 be
HDR 1010 20090820 20090820 181007 77000 7010
detail3 0000 cccccccccccccccccccccccccc
detail4 0000 dddddddddddddddddddddd
detail5 0000 bbbbbbbbbbbbbbbbbbbbbbb
TRL 1010 20090820 20090820 181007 77000 7010 00003
The TRL has record count field at last 00002 & 00003 for the two files.
My requirement is to get FILE3
HDR 1010 20090820 20090820 181007 77000 7010
detail1 0000 aaaaaaaaaaaaaaaaaaaaaaa
detail2 0000 bbbbbbbbbbbbbbbbbbbbbbb
detail3 0000 cccccccccccccccccccccccccc
detail4 0000 dddddddddddddddddddddd
detail5 0000 bbbbbbbbbbbbbbbbbbbbbbb
TRL 1010 20090820 20090820 181007 77000 7010 00005
here count should be count of file1 ,file2.we can use the below to take only detail records.
INCLUDE COND=(1,3,CH,EQ,C'DET')
All the detail part will have detail as suffix.
Please let me know to achive this