NAME Statement



The NAME statement is always the last statement in the sequence as it terminates the control statement set relevant to this program, which it also names.

If it is known that the member already exists and is to be replaced, append (R) to the module name.

The module name may also be assigned by appending a member name in parenthesis to the data set name on the SYSLMOD DD statement. This latter method will always replace a member with the same name.




//L        EXEC PGM=HEWL,
//             PARM='MAP,LET,LIST,NCAL',
//             COND=(8,LT,C)
//SYSLIN   DD  DSN=&&OBJ,DISP=(OLD,DELETE)
//         DD  DDNAME=SYSIN
//SYSLMOD  DD  DISP=SHR,DSN=real.livbrary
//*SYSLMOD  DD  DISP=SHR,DSN=real.library(progname)
//SYSUT1   DD  DSN=&&SYSUT1,
//            SPACE-(1024,(120,120),,,ROUND),
//            UNIT=VIO,DCB=BUFNO=1
//SYSPRINT DD  SYSOUT=*
//MYLIB    DD  DISP=SHR,DSN=program.libarary
//SYSIN    DD  *
  ENTRY   start_point
  INCLUDE MYLIB(mainprog)
  NAME    progname


If used, the NAME statement must be the last statement in any group of statements relevant to a particular module or program.

Copyright © Legac-e Education 2015-