Sort tricks in jcl pdf

A file has 100 records. The first 10 records need to be written to output file. The option STOPAFT will stop reading the input file after 10th record sort tricks in jcl pdf terminates the program.

Hence, 10 records are written to output. Input file has one or more records for same employee number.

Write unique records to output. NONE removes duplicates on fields specified in SORT FIELDS.

In the above example, employee number is in the field position 1,15. The output file will contain the unique employee numbers sorted in ascending order. In the input file, the content in position 1,6 is overwritten to the position 47,6 and then copied to the output file. INREC OVERLAY operation is used in order to rewrite data in input file before copying to output.