Exforsys

Home arrow Technical Training arrow MainFrame Tutorials

Introduction to JCL Page - 2

Page 2 of 2
Author : Exforsys Inc.     Published on: 8th Nov 2006    |   Last Updated on: 11th Mar 2011

Introduction to JCL

Ads

Programmer name

Programmer name parameter is used for user identification
for routing printouts. This can be 1 to 20 characters long and is specified in single quotes if name contains spaces or special characters other than periods. Hyphen cannot be used in this parameter. If you want to include single quotes in the name it must be specified as double quotes

Example:

//SAMP1 JOB (bb12,cc34,dd67),‘nam xx’
//SAMP2 JOB (S456), Name5

The keyword parameters

A variety of keyword parameters can be specified on the JOB
statement. They are namely:

  • CLASS
  • COND
  • MSGCLASS
  • MSGLEVEL
  • NOTIFY
  • PASSWORD
  • PRTY
  • REGION
  • RESTART
  • TIME
  • TYPRUN
  • USER

The keyword parameters always follow positional parameters and parameter in this is separated by commas.

//jobname

Let us see how to use the parameters

CLASS

This indicates the type of JOB submitted to the system. It specifies input class for JOB scheduler. It is a single alphanumeric character namely (a-z, 0-9). Different classes will represent different types of jobs and will depend on installation.

CLASS=A - test jobs
CLASS=B - production jobs

Example

//SAMP1 JOB (S456),CLASS=A

MSGCLASS

This determines the o/p device to which system messages and JCL messages are written. This is a single alphanumeric character namely A-Z, 0-9. It depends on JES set-up.
MSGCLASS=T - output to terminal

Example:

//SAMP2 JOB CLASS=A,MSGCLASS=T

MSGLEVEL

MSGLEVEL parameter is used to specify JCL and allocation messages which will be recorded on the output device specified in MSGCLASS.

Syntax is:

MSGCLASS= (statements,messages )

In this statements can take value 0 or 1 or 2. This represents

  • 0 Only JOB statement
  • 1 All input & procedure statements
  • 2 Only input JCL statements

In this messages can take value 0 or 1 or 2. This represents

  • 0 Allocation/termination messages being output if the job terminates abnormally.
  • 1 Allocation/termination messages being output if the job terminates normally or abnormally.

EXAMPLE:

//SAMP1 JOB (S456),NAM,MSGLEVEL=(0,0)
//SAMP2 JOB (S356), NAM1,MSGLEVEL=(1,1)

USER/PASSWORD

This parameter is used for security checking purpose .The user parameter specifies your RACF user id. The user id is used during the job's processing by RACF and JES to identify the user who submitted the JOB for security checking purposes

EXAMPLE:

//SAMP1 JOB (S456),'SRI PRIYA',
// CLASS=A,MSGCLASS=R,
// NOTIFY=SRI456,USER=SRI456,
// REGION=4096K,TYPRUN=HOLD

COND

This Specifies whether a JOB should continue to execute or terminate
in relation to the outcome of any JOB step. If condition is true, the JOB is terminated.

Syntax:
COND= (code, operator)

In this code takes value 0 to 4095 and operator can be any one of GT, GE, EQ, LT, LE, NE

Eg. Cond=(1, EQ) means:

If 1 is equal to the condition code returned by any JOB step, terminate the JOB. In other words, the JOB will execute only if all job steps return a condition code not equal to 1

TIME

This parameter specifies the maximum CPU time for a JOB.
System will automatically cancel the JOB if its execution time exceeds the specified time.

Syntax:
TIME=(MINS,SECS)

E.G. TIME=(2,20) maximum CPU time for this JOB is 2minute and 20 seconds

Typrun
This has two values namely

  • SCAN causes JCL to be scanned for syntax errors only
  • HOLD causes JOB to be held in input queue until explicitly released by the operator

Restart
This enables the execution of a JOB from a particular step instead from the top of the JOB step.
Syntax:
RESTART=STEPNAME

Ads

PRTY
This determines priority for scheduling jobs within each class and it value ranges from 0-15. The more the number, higher will be the priority.

REGION
This specifies amount of space JOB requires and it can be specified in kb or mb
Syntax:
REGION=NK/NM

Example:
//SAMP5 JOB (S456),’SRI PRIYA’,CLASS=A,PRTY=3,REGION=4092K, TYPRUN=HOLD



 
This tutorial is part of a MainFrame Tutorials tutorial series. Read it from the beginning and learn yourself.

MainFrame Tutorials

 

Comments