Describe the DD statement, its meaning, syntax and keywords?

The DD statement links the external dataset name (DSN) to the DDNAME coded within the executing program. It links the file names within the program code to the file names know to the MVS operating system. The syntax is // ddname DD DSN=dataset name. Other keywords after DSN are DISP, DCB, SPACE, etc.

Showing Answers 1 - 4 of 4 Answers

Renuka Mudaliyar

  • Apr 3rd, 2006
 

Its the Data Definition (DD) statement

It should not exceed 8 characters

It is normally the identifier name which we give in the cobol program to identify the that the trailing DSN is for the particular DD name 

for eg:

COMMLY   DD   DSN=ABCD.PQRS.XYZ,DISP=SHR

Here,COMMLY is the ddname

dhs01

  • Apr 15th, 2009
 

DD statement is the DATA DEFINITION Statement.
It's function is to give a symbolic name to a file. This will allow a program to access a file through this name so that the file name may be changed without effecting the program. There are several parameters that may be specified about the file included on this statement. These parameters are merged with information from the program and/or the device/catalog. There are far too many keywords to describe here and the syntax is pretty straight forward, // in col 1,2 col 3 starts the ddname which can be up to 8 characters followed by at least 1 space and DD followed by atleast 1 space, then come the optional positional parameters, Keyword parameters follow any positional parameters. Parameters are separated by a comma and if you wish to extend it to another card, that card will start with a // in col 1,2 followed by atleast one space and more parameters. You may add comments after the parameters by including at least 1 space. Do not code past col 72  

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions