DFSORT JCL (Step SORT12)

This program sorts the MEDAR12O data set that is created by FABBME3. The sorted data set is used by FABADA5.

EXEC statement

The EXEC statement must be in the following form:
//     EXEC PGM=SORT

DD statements

To run DFSORT, you must supply the appropriate DD statements. The following table summarizes the DD statements. Actual JCL requirements are as follows:

Table 1. DFSORT DD statements (Step SORT12)
DDNAME Use Format Required or optional
SORTIN Input LRECL=20 Required
SYSIN Input Required
SORTOUT Output LRECL=20 Required
SYSOUT Output SYSOUT Required
SORTWK01 Work data set Required
SORTWK02 Work data set Required
SORTWK03 Work data set Required

The following table shows space requirements for this JCL stream.

DDNAME Space requirements
SORTOUT # CI/area X 1.5 X 20 bytes
SORTIN DD
This input data set is the MEDAR12O file from FABBME3.
SYSIN DD
This input data set contains DFSORT control statements. It is the SORT12 file from FABBME3.
SORTOUT DD
This output data set contains the sorted records. It is used by FABADA5. Required space is the same size as the SORTIN data set. Do not specify DISP=MOD for this DD statement.
SYSOUT DD
This output data set contains the messages produced by DFSORT.
SORTWKnn DD
These are the intermediate storage data sets used by DFSORT. See DFSORT Application Programming Guide for more information about creating SORTWKnn DD statements.

Allocating twice the space used by the SORTIN data set is usually adequate for each work data set.