Reusable JCL collection
Previous topic | Next topic | Contents | Glossary | Contact z/OS | PDF


JCL statements: What does the DD statement do?

Reusable JCL collection

Data definition (DD) statements define the data sets that a program or procedure uses when it runs. You must code one DD statement for each data set that is used or created within a job step.

The order of DD statements within a job step is not usually significant.

This JCL example illustrates the format of a DD statement:
//PAY  DD  DSN=HLQ.PAYDS,DISP=NEW  VENDOR PAYROLL
  • The name field contains a one- through eight-character name, known as a ddname, that identifies the DD statement so that other JCL statements, programs, procedures, or the operating system can refer to it. The ddname of this DD statement is PAY.
  • The parameter field contains only two keyword parameters:
    • DSN, which is an accepted abbreviation for the parameter DSNAME, which identifies the real name of a data set.
    • DISP, which identifies the data set HLQ.PAYDS as a new data set; that is, one the system is to create when this job is submitted for processing.
  • The comment field contains the phrase VENDOR PAYROLL.
A DD statement describes a data set extensively, and can include the following information:
  • The name that the program uses to refer to the data set, known as the ddname
  • The actual name of the data set and its location
  • Physical characteristics of the data set, such as record format
  • The initial and final status of the data set, known as its disposition

You also can use DD statements to request I/O devices or specify storage allocation for new data sets.





Copyright IBM Corporation 1990, 2010