SORT-MERGE/XL General User's Guide (32650-90883)

62 Chapter5
Using SORT-MERGE/XL in Batch Mode
Initiating a Batch Job
4 OUTPUT COMPANY
5 KEY 1, 11; 12, 11
6 END
7 !EDITOR
8 TEXT COMPANY
9 LIST ALL
10 EXIT
11 !EOJ
12 //
/KEEP RUNSORT
You have created a job file named RUNSORT. It may be used to generate reports on the data
in the input file EMPLOYEE. It can also be used to generate a sort on any other input file by
modifying the lines in the job file containing the INPUT and TEXT commands (see lines 3
and 8 in the example above).
Every time you run this job, you need to modify the line containing the name of the output
file. If a unique name is not supplied, the system issues the message:
OUTPUT FILE CLOSED WITH FILENAME OUTPUT1
This is followed by the SORT/XL statistics, and then another message:
PROGRAM TERMINATED IN AN ERROR STATE. (CIERR 976)
REMAINDER OF JOB FLUSHED.
CPU SEC. = 3. ELAPSED MIN. = 1. WED, JUN 3, 1987, 1:05 PM
If the system finds an existing file name for the output file, it supplies the file name
OUTPUT1, OUTPUT2, ...OUTPUT
n
by successive ascending numbers and then aborts the job
in an error state.
If this occurs, either purge the existing file COMPANY, or provide a unique name for the file
designated by OUTPUT. Be sure the file designated by >OUTPUT and the file accessed by the
editor are the same.
Initiating a Batch Job
To send the job file RUNSORT to the computer for processing, exit the editor subsystem.
Then at the MPE XL colon prompt (:), enter:
:STREAM RUNSORT
Once this command has been received by the system, it issues a job number identifying
your job, as follows:
#J555
The following section explains how to use this number to check on the status of your job.