JCL Basics What is JCL? Job Entry Subsystem Job Processing JCL Statements JCL Parameters JOB Statement Job Statement Parameters for Job Positional Parameters ACCT NAME Keyword Parameters MSGLEVEL MSGCLASS TYPRUN PRTY CLASS RESTART REGION TIME NOTIFY EXEC Statement EXEC Statement Positional Parameters PGM PROC Keyword Parameters COND PARM ADDRSPC DD statement DD statement DD Parameters SPACE SYSIN VOL DCB SYSOUT DSN UNIT DISP |
DISP parameter • DISP=(status,normal-disposition,abnormal-disposition) <IMAGE> • The DISP parameter specifies - The current status of the data set. - If a dataset has to be created newly, or if it is already present. - If it is already present, what should it do with the existing contents. • It directs the system on what has to be done at the end of the JOB (The job may end normally or abnormally). • DISP parameter has three terms namely status, normal-disposition, abnormal-disposition. The various options for these three terms are shown above inside curly braces. Status: • The status, NEW, MOD, OLD, or SHR, is the status of the data set at the beginning of the step. • If the data set is new, the system creates a new data set label. • If the dataset is old, the system locates the data set and reads the label. Except for SHR the system gives a program exclusive use of a data set. • Several programs can read a data set at the same time if they all have a DISP of SHR. NEW is given to create a new data set. NEW is the default, if nothing is coded. OLD designates an existing data set. • MOD is used to extend an existing sequential data set or to create the data set if it does not exist. Normal and abnormal disposition: • DELETE The data set is deleted. If it was retrieved from the catalog, it is also uncataloged. • KEEP The data set is retained. • CATLG The data set is retained and a catalog entry is made. • UNCATLG The data set is retained, but its catalog entry is removed. • PASS This is for normal disposition only. The data set is retained for use by a later job step. Default values: • If status parameter is omitted, operating system assumes it as NEW. • The default value for normal disposition depends on the value specified or assumed for status parameter. • If STATUS=NEW, normal disposition is DELETE. • If STATUS=OLD, SHR, or MOD, normal disposition is KEEP. • In the case of abnormal disposition the default value is taken on the values specified or assumed for normal disposition. |