COBOL Manual for TNS/E Programs (H06.08+, J06.03+)

The swap file is a temporary file with a volume but no subvolume. If you specify a swap file,
including a volume, the volume is used but the file-id is not. If you specify only a file-id,
the default volume is used.
If COBOL_SET_SORT_PARAM_TEXT_ specifies a SWAP-FILE, then the swap file is created
on that file’s volume.
If the SELECT statement associated with merge-file specifies the =_SORT_DEFAULTS
DEFINE as the define-name-literal, then:
If the =_SORT_DEFAULTS DEFINE exists and specifies a swap file, then the swap file
is created on that file’s volume.
If the =_SORT_DEFAULTS DEFINE exists but does not specify a swap file, then the
swap file is created on the volume used for the scratch file.
If no =_SORT_DEFAULTS DEFINE exists, then the swap file is created on the volume
used for the scratch file.
For more information on the =_SORT_DEFAULTS DEFINE, see Establishing Parameters
With =_SORT_DEFAULTS DEFINE (page 611).
If the SELECT statement associated with merge-file does not specify the
=_SORT_DEFAULTS DEFINE as the define-name-literal, then the swap file is created
on the volume of the file that the SELECT statement specifies.
In Example 112, a MERGE statement merges two files to produce a third.
MERGE 367