JCL 3 - Keyword Parmeters at Activity Level

PGM : This is a positional parameter which must be coded after Exec with one blank. This parameter indicates the name of the program/utility of IBM .

//JOB12345      JOB (KUMACT), “REPORT1”, CLASS=A, MSGCLASS=A,MSGLEVEL=(1,1) ,
//                              PRTY=4,NOTIFY=&SYSUID       

//ACTVTY1      EXEC   PGM=REPORT

PARM : It is keyword parameter and it is mainly used for passing the data to a program.
There are two ways to passing the  data.

Method I : using PARM: This is a keyword parameter at activity level must be coded with Exec operand after PGM parameter. This parameter allows max (100) characters, they consists of predefined text/system defined commands.

The PARM parameter can be used to pass data to user/system defined programs
To receive PARM parameter data, Cobol program must be coded with “PROCEDURE DIVISION USING PARAMETERS” option. These parameters must be declared in the linkage section.

Ex JCL:

//JOB12345      JOB (KUMACT), “REPORT1”, CLASS=A, MSGCLASS=A,MSGLEVEL=(1,1) ,
//                              PRTY=4,NOTIFY=&SYSUID       

//ACTVTY1      EXEC   PGM=REPORT, PARM=”2014-12-08” -->  date”(max 100 characters, no
separator is coded and size in cobol is only the separator)


Previous
Next Post »