Example 8
-
The JOB statement gives MULTOUT as the jobname.
-
The EXEC statement identifies SYNCSORT as the program to be executed.
-
The STEPLIB DD statement instructs the system to look for MFX in the library named SORT.RESI.DENCE. The DISP parameter shows that the library may be shared.
-
The SYSOUT DD statement assigns the MFX messages to the output device associated with SYSOUT class A.
-
The SORTIN DD statement gives SALES.RECORDS as the input data set name, and specifies a disk with the volume serial DISK1. The DISP parameter indicates that the data set is already in existence and may be shared.
-
The SORTOUT DD statement names one of the output sorted files SORTED.SALES.RECORDS, and specifies a tape device with volume serial number 112233 for storage. The DISP parameter indicates that the data set does not yet exist, but it is to be kept whether or not the job terminates normally.
-
The SORTOFDS DD statement names a second sorted output file DOMESTIC.SALES.RECORDS, and specifies a disk device with volume serial number DISK8 for storage. Forty cylinders of space have been allocated on this volume. The DISP parameter indicates that the data set does not yet exist, but is to be kept whether or not the job terminates normally.
-
The three SORTWK DD statements reserve space on direct access devices for intermediate storage. Twenty cylinders are allocated for each of the three SORTWK data sets.
-
The SYSIN DD statement marks the beginning of the input stream that includes the sort control statements.
-
The SORT control statement specifies that one control field will be sorted on. It begins on byte 10 of the record, is 12 bytes long, contains unsigned binary (BI) data and is to be sorted according to ascending order.
-
The first OUTFIL control statement is associated with the SORTOUT DD statement. The INCLUDE parameter specifies that all input records are to be included in this output file.
-
The second OUTFIL control statement is associated with the SORTOFDS DD statement. The OMIT parameter specifies that records which do not contain “USA” in bytes 62, 63 and 64 are not to be included in this file.
-
The delimiter statement marks the end of the SYSIN input stream.