I tried generating the JCL but, the symbols from the SORTIN file was not replaced. I am sure am doing something stupid.
Can someone pls help me out on where I have gone wrong?
I am trying to substitute the date from the input file which i have defined using symnames to the third node of the dataset (DTMMDDYY)
//STEP2 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SYMNOUT DD SYSOUT=*
//SYMNAMES DD DSN=<symname dataset with symbol definitions>,DISP=SHR => def given @ top of this post
//SORTIN DD DSN=<symname dataset with data>,DISP=SHR => data given @ top of this post
//SORTOUT DD SYSOUT=(*,INTRDR)
//SYSIN DD *
HEADER1=('//XXXXXXX$ JOB (nnnnnT,xxxxxxxx),CLASS=A,MSGCLASS=X,',/,
'//STEP6 EXEC PGM=SARBCH',/,
'//SYSPRINT DD SYSOUT=*',/,
'//LISTOUT1 DD DSN=A.B.DTMMDDYY,',/,
'//SYSIN DD DSN=<control card for SARBCH>,DISP=SHR')
You can use the symbols in the SYMNAMES data set to select fields from the input record for use in the output records. You would just use the appropriate symbols where you need them. Here's the correct DFSORT job (I've corrected your LISTOUT1 line as indicated):