mainframe jcl part - 1
TRANSCRIPT
MAINFRAMES REFRESHER PART-1 JCL
JCL Job Control Language (JCL) is a name for
scripting languages used On IBM mainframe operating systems to instruct the system on how to run a batch job or start a subsystem.
JCL acts as an interface between application programming and MVS Operating system.
Jcl is used for compilation and execution of batch programs.
MAINFRAMES REFRESHER PART-1 JCL
Apart from the above functionalities JCL can also be used for,
1. Controlling the jobs. 2. Create GDG’S.
3. Allocate PDS,PS file with IBM Utilities.
4. Create Procs.
5. Sort the files.
JCL Coding Sheet
1,2,3----------Column Numbers----------72,73------------80
//JOBNAME JOB PARAMETERS------COMMENTS
// EXEC
// DD//* ------------ Comment (* in 3rd column indicates line in comment)//------------ End of JCL
MAINFRAMES REFRESHER PART-1 JCL
Where // ----- Identification Field
job name------- Naming field
JOB,EXEC,DD - Statement / Operation
NOTE
If we want to continue parameters in the next line end the last parameter with “,” and continue next parameter only in 4-16 columns.
There are three statements in JCL. JOB EXEC DD
MAINFRAMES REFRESHER PART-1 JCL
JOB Statement:
Job statement is used to identify job name and job related parameters
JOBCARD = job name + job related parameters.
Syntax
//JOBNAME JOB ACCOUNT INFORMATION,’USERNAME’,CLASS=A-Z/0-9,// NOTIFY =&SYSUID/RACF ID,MSGCLASS,// MSGLEVEL=(X,Y),PRTY=0-15,// TIME=(M,S),REGION=MB/KB,TYPRUN=SCAN/// HOLD/COPY,COND=(RC,OPERATOR,STEPNAME)// COND=ONLY OR COND=EVEN,RESTART=STEPNAME
MAINFRAMES REFRESHER PART-1 JCL
JOBNAME It is required to identify this job from other jobs in the
SPOOL 1 to 8 characters minimum 1 character and maximum
is 8 character. 1st character must be alphabet. Other characters can be alphabets or numeric or $,&,#.
Example Job names for personal or lab sessions
Userid + 1 / 2 charsKC03P83$ ------- Userid is KC03P83 KC03P84&--------Userid is KCO3P84
MAINFRAMES REFRESHER PART-1 JCL
ACCOUNTING INFORMATION
It is a keyword parameter and codes it after JOB statement.
It is used for billing purpose, in real time when we submit any job it is going to take some CPU time. Based on the CPU time there will be some amount involved where this amount has to go will be decided by A/C information parameters.
Examples (8012T)(80121I)(8012M)
MAINFRAMES REFRESHER PART-1 JCL
USERNAME
It is used to identify the user who has written the JCL.
It can be maximum of 20 characters.
Note Both A/C information and user name are positional parameters and the remaining job
card parameters are keyword parameters.
EX1: //KC03P83A JOB (487A),’JANAKI RAM’
EX2: //KC03P84& JOB (488T),’SOMISETTY’
MAINFRAMES REFRESHER PART-1 JCL
NOTIFY
To which user id the job has to be notification after successful or unsuccessful completion.
Successful completion means MAXCC = 0 (or) 04 unsuccessful completion means MAXCC > 04.
If it is not coded,then user has to check the status of the job from the spool.
It has two methods.
NOTIFY = USERID------ When userid is given then it will notify to the given user.
NOTIFY = &SYSUID----- When &SYSUID is given then it will it replace current USERID
MAINFRAMES REFRESHER PART-1 JCL
CLASS
It is used to assign the properties to the job. Suppose if you submit at the job at the same time which job has to run first time and which job has to run 2nd time and so on will be decided by class parameter.
Note This class parameter priority is set by MVS Admin Team
It has single character from A-Z Each class has properties on resources over the other
classes
MAINFRAMES REFRESHER PART-1 JCL
CLASS
Real Time Examples
Class = P----- Production Class Class = M---- Model/UAT Class Class = I ----- SIT Class
A – Short Running ClassB – Long Waiting ClassC – Long Running Class
In test region more users submit their jobs, so more classes required.
In SIT/UAT/PROD most of jobs are submitted one after the other.