themants
New User
Joined: 11 Aug 2022 Posts: 9 Location: india
|
|
|
|
I have 2 files. For the specific condition match in 2nd file, I need to skip the relevant account details from file 1 as well in the output file but all records besides skipped account number from file 1 must be present in output file.
**************************
File 1 input -
ACC0001RNB
ACC0002RNB
ACC0003RNB
ACC0004RNB
ACC0005RNB
ACC0006RNB
**************************
File 2 input -
ACC0001C01
ACC000203L
ACC0002C03
ACC0003139
ACC0003A11
ACC0004C04
Here, for each account number, for position no 8, if we have 'C0' and '3' or '4' at 10th position, we don't need the relevant record from file 1 but all records beside those from File 1.
**************************
Expected output -
ACC0001RNB
ACC0003RNB
ACC0005RNB
ACC0006RNB
**************************
i have tried below OMIT login and relevant include logic by changing the logic part but its still giving me account number AC0002 in output file which is not required.
SORT FIELDS=(1,7,CH,A)
JOINKEYS FILE=F1,FIELDS=(1,7,A)
JOINKEYS FILE=F2,FIELDS=(1,7,A)
OMIT COND=(8,2,CH,EQ,C'C0',AND,
(12,1,CH,EQ,C'3',OR,12,1,CH,EQ,C'4'))
REFORMAT FIELDS=(F1:1,489),FILL=C'
Can anyone help me resolve this? |
|