Team,
I am trying to add the trailer record to build TRL and date and time in the output DYNAMIC sort card but getting lot of errors. could anyone please help on this
I have the input file as like below
xxxxxxxx 20200412101223
yyyyyyyy 20200312101128
Sort card to prepare a dynamic Sort card
SYSIN DD *
OPTION COPY
INCLUDE COND=(1,8,CH,EQ,C'XXXXXXXX')
OUTFIL REMOVECC,
HEADER1=('SORT FIELDS=(57,8,ZD,D)'),
BUILD=(C' INCLUDE COND=((57,8,ZD,GT,',9,8,C'),OR,',40X,/,
C' (57,8,ZD,EQ,',9,8,C',AND,65,6,ZD,GT,',17,6,C')),
C('TRAILER1=('TRL',DATE=(4MD/),TIME=(24)))')
output what i expect
SORT FIELDS(57,8,ZD,D)
INCLUDE COND=((57,8,ZD,GT,20200421), OR,
(57,8,ZD,EQ,20200421,AND,65,6,ZD,GT,101223))
TRAILER1=('TRL',DATE=(4MD/),TIME=(24))
EXCEPT THE TRAILER, ITS WORKING FINE. TRAILER IS GIVING LOT OF SYNTAX ERRORS IN THE TRAILER LINE RC 0008
Thanks in Advance
OPTION COPY
INCLUDE COND=(1,8,CH,EQ,C'XXXXXXXX')
OUTFIL REMOVECC,
HEADER1=('SORT FIELDS=(57,8,ZD,D)',/,
' INCLUDE COND=((57,8,ZD,GT,',9,8,C'),OR,'),
Build=(C' (57,8,ZD,EQ,',9,8,C',AND,65,6,ZD,GT,',17,6,C'))',80:x),
TRAILER1=(C' OUTFIL,REMOVECC,',/,
''TRAILER1=(C''TRL'',DATE=(4MD/),TIME)',80:X))