Example 6
-
The JOB statement gives ONE#EXIT as the jobname.
-
The EXEC statement identifies SYNCSORT as the program to be executed. The MSG PARM option requests that all messages be routed to the SYSOUT DD statement but only critical messages be routed to the console.
-
The STEPLIB DD statement instructs the system to look for MFX in the library named SORT.RESI.DENCE. The DISP shows the library may be shared.
-
The SYSOUT DD statement assigns the MFX messages to the output device associated with SYSOUT class A.
-
The MODLIB DD statement defines the library in which the exit routine resides; MODLIB is referenced in the MODS control statement. The data set name of the library is EXIT.E15, and the DISP shows that the library may be shared.
-
The SORTIN DD statement gives INPUT as the input data set name and specifies a 3390 disk with the volume serial number ABCDEF. The DISP parameter indicates that the data set is already in existence and may be shared.
-
The SORTOUT DD statement gives OUTPUT as the output data set name and specifies a 3390 disk with the volume serial number GHIJKL. Ten cylinders of primary space have been allocated on this volume. The DISP parameter shows that this data set is not yet in existence.
-
The four SORTWK statements reserve space on four temporary data sets for intermediate storage. Twenty cylinders are to be reserved on the first two data sets, fifteen on the second two data sets.
-
The SYSIN DD statement marks the beginning of the input stream that includes the sort control statements.
-
The SORT control statement specifies two sort control fields. The first begins on byte 10 (data byte 6) of the record, is 25 bytes long, contains character data, and is to be sorted in ascending order. The second control field begins on byte 40 (data byte 36) of the record, is 10 bytes long, has zoned decimal data, and is to be sorted in descending order. FILSZ instructs MFX to terminate abnormally unless the post-E15 file contains exactly 9,000 records.
-
The RECORD control statement shows that variable-length records are being sorted. The first LENGTH value reports that the maximum length of records in the SORTIN data set is 1024 bytes. The comma coded for the second LENGTH value shows that this maximum length is not altered by the exit routine. The comma coded for the third LENGTH value shows that this maximum length is not affected by an E35 or the INREC/OUTREC statements. The fourth LENGTH value shows that the smallest record in the input data set is 44 bytes long. The fifth LENGTH value shows that the record length that occurs most frequently in SORTIN is 192 bytes. (This value will be used to determine segment size.)
-
The MODS control statement states that the exit-type is E15. The name of the actual exit routine included at this exit is also E15. The routine requires 600 bytes of memory and resides in a library defined on the MODLIB DD statement. Finally, the N indicates that link-editing of the routine has already been performed.
-
The END control statement marks the end of the control statements.
-
The delimiter statement marks the end of the SYSIN input stream.