Skip to content
JCL & batch

DD statement

The JCL statement that connects a name inside a program to a real dataset outside it.

Also written //DD, data definition

DD stands for data definition. These statements do the most interesting work in JCL: they connect the file names a program uses internally to actual datasets on the system.

A COBOL program does not name a dataset in its code. It refers to a file by a symbolic name, and the DD statement with that name supplies the real dataset when the job runs. That indirection is the whole point. The same compiled program can process test data one day and production data the next, with only the JCL changing.

A DD statement says which dataset to use, whether it already exists or is being created, what should happen to it when the step ends, and if it is new, how big it should be and what shape its records are.

It can also supply data directly inline in the JCL, which is how utilities receive their control statements, and it can direct output to the spool for you to read afterwards.

Most JCL errors people meet early are DD errors, and most of those are a name that does not match or a dataset that is not where it was expected.

Browse all 115 terms

Learn this properly.

Use DD statement for real in Mainframe101, in your browser, with Zed beside you. Join the waitlist.

Early access and updates. No spam, unsubscribe any time.