JCL sort card to sort selected fields

The below is the sort card that you can use in sysin dd* to sort only few selected fields present in the input file.

SORT JCL
SORT JCL
//EXAMP   JOB A492,PROGRAMMER
//SORT    EXEC PGM=SORT
//SYSOUT  DD   SYSOUT=A
//SORTIN  DD   DSN=A123456.SORT.SAMPIN,DISP=SHR ==> Input file
//SORTOUT DD   DSN=A123456.SORT.SAMPOUT,DISP=OLD ==> Output file
//SYSIN DD *
  SORT FORMAT=CH,
  FIELDS=(110,10,A,145,17,A,1,75,A)
/*
Advertisements

Author: Srini

Experienced software developer. Skills in Development, Coding, Testing and Debugging. Good Data analytic skills (Data Warehousing and BI). Also skills in Mainframe.