• Appreciate the need for Job Control Language. • Have an overview of Job Control Language in IBM environment. • Know the structure of Job Control Language statements. • Know the usage of the various parameters of Job Control Language statements. • Know the structure of Job Control Language procedures. • Know the concept of Generation Dataset Groups. • Know the purpose and usage of common IBM utilities. • Be able to write JCLs and test them on MVS workbench. • Appreciate the relation between COBOL program and JCLs.
SESSION -- I
To understand • • • • What is a JCL ? Why JCL is required ? Overview of Job Entry Sub-System Various components of a JCL statement.
JOB CONTROL LANGUAGE ( JCL )
• Job Control Language is a means of communication between a program and the MVS Operating System. • Without JCL, no program can run on an IBM Mainframe.
• JCL is not a procedural language.
• Provides primary interface between user and JES ( Job Entry Subsystem ). • Used to perform batch mode processing under MVS. • Within a job, JCL provides the specification necessary for MVS to process the job.
* Data file identity.• Specifications for a job are
* User identity.
. * Resource Requirement. * Error handling.
Printer). • To specify the I/O devices required by the job ( Tape. • To identify the directory and data files required for the job. Disk.
.WHY JCL ?
• To identify themselves (users) to the system for security and accounting purposes. • To specify what action the system should take in exceptional cases.
. • Each initiator is associated with one or more jobs.
• JES processes jobs based on job class and priority.JOB ENTRY SUB SYSTEM
JES is a MVS component assigned with the task of keeping track of Jobs that enter the system. • This scheduling of job is handled by a special type of program called Initiator. present them to MVS for processing and send their spooled output to correct destination.
• The interpreter’s job is to examine the job information passed to it by JES and create a series of control blocks in the address space.
Contd..HOW JOB IS EXECUTED
• The Initiator selects a job for execution and invokes the interpreter. • For each job step the initiator invokes Allocation Routines to allocate resources (units. volumes and data sets) required by the job step.
HOW JOB IS EXECUTED ( Contd.
• The Initiator then creates a user region. • When the execution of user program is complete. the initiator invokes routine to deallocate the resources used by the job step. loads the user program into it and transfers control to the user program.
• Sysprint : output listing for sysprint data set which specifies sysout =A
. • JCL listing: lists the JCL steps performed. • The Message Log : shows system messages concerning the execution of job steps and the allocation and deallocation of data sets.OUTPUT LISTING GENERATED AFTER JOB EXECUTION
• Job log : is a record of JES messages written to the operator’s console as well as the operator’s reply where appropriate.
Must begin in column 3 if coded. Exceptions: (1) for a delimiter statement.//* starting in column 1.(2) for a comment statement.. Contd.BASIC FORMAT OF JCL STATEMENTS identifier [name] [operation] [parameters] [comments] Explanation Identifier Two slashes starting in column 1. starting with a letter or national character.
./* starting in column 1. O ne to eight alphanumeric or national characters.
EXEC.or DD. Comments Comments may follow the parameters.Operation
A valid operation code.
Parameters One or more parameters depending on the operation.preceded by one space and not extending beyond column 71.such as JOB. Must be preceded and followed by a space.with no intervening spaces. Individual parameters are separated from one another by commas.
. CLASS=A. The statements in the sample JCL can be categorized into five different fields. PRTY=6.
// Name // JOB1 Operation Parameters Comments JOB (P155). // STEP1 EXEC PGM= PROGRAM1 // REPORT1 DD SYSOUT=A //
To understand • • • Job statement Positional parameters in JOB statement Keyword parameters in JOB statement
To try and solve classroom exercises.
• In JCL.
. It contains several JCL statements that instruct the operating system what to do. a job can be considered as a unit of work that has to be executed. • The job statement identifies the beginning of a job to the operating system.
// NAME // JOBNAME
OPERATION PARAMETERS COMMENTS COMMENTS JOB OPERANDS < POSITIONAL / KEYWORD PARAMETERS >
.The format of the statement is as given below.
.JCL PARAMETERS ON THE JOB STATEMENT
FUNCTION Specification of the job Specification of job name Specification of accounting information Specification of the programmer name CORRESPONDING JCL PARAMETER JOB JOBNAME (ACCOUNTING INFORMATION)
(JCL PARAMETERS ON THE JOB STATEMENT Contd..)
CORRESPONDING JCL PARAMETER Categorization of job CLASS Specification of output MSGCLASS class to job log Specification of MSGLEVEL printing the system messages Assignment of priority PRTY to a job Holding a job for later TYPRUN execution FUNCTION
. • The #. • The first character of the name must be alphabetic or national. immediately following
the double slashes. and $ symbols can also be included in the name.
• It must be followed by at least one space.
It cannot be numeric. • Valid names can be 1 to 8 alphanumeric characters in length. @.JOBNAME
• The jobname must start in column 3.
Some examples of valid job names //cci9393 //r4 Some examples of invalid job names //122fsf ( number is coded as the first character ) // safasfa ( space coded after the slashes ) //afasfjlasfjlasf ( jobname is longer than 8 characters )
.POSITIONAL PARAMETERS IN JOB STATEMENT
• Job accounting information parameter.
• Programmer name parameter.
JOB ACCOUNTING INFORMATION PARAMETER
• Accounting information in an IBM mainframe environment is used to bill or charge back any job that is run on the mainframe. • The accounting information parameter identifies the account number which will be billed for the CPU time utilized on the mainframe.
( account-number, additional accounting information)
EXAMPLE 1 : //JOB1 JOB (A123,DEPT1)
JOB1 is the name of the job. JOB is the operation. A123 is the account number. DEPT1 is the additional accounting information. Since both the parameters are coded, they are enclosed in the parenthesis.
EXAMPLE 2 :
//JOB1 JOB ‘A123, DEPT1’
Programmer name parameter specifies two things:
Programmer name Information related to the job being submitted.
It should be coded immediately after the accounting information parameter
//JOB1 JOB (A123), VENU
The parameters in this statement are: The double(//) slashes are required at the start of each JCL statement, in columns 1 and 2. JOB1 is the job name and immediately follows the double slashes. JOB is the operation. (A123) is the account number. VENU is the programmer name parameter.
• Keyword parameters must follow positional parameters. • They can be coded in any order. Some of the keyword parameters are : CLASS PRTY MSGCLASS MSGLEVEL TYPRUN NOTIFY
• A Jobclass identifies the nature of the job that is to be
• Jobs can be short-running or can take a long time.
The class parameter assigns a Jobclass to a job. there by categorizing the job being submitted.
• The Jobclass is used to identify these characteristics to the
operating system. or may
utilize heavy resources.
//JOB1 JOB ( A123). VENU.SYNTAX
CLASS= Job class Where job class is any character between A-Z or number between 0-9. CLASS=K
PRTY=priority Priority can range between 0 to 14. or 0 to 15. depending on what job entry subsystem (JES2 or JES3) is being run at the time.‘PRTY’ PARAMETER
• The PRTY parameter
is related to the CLASS parameter.
. It assigns priority to jobs which belong to the same class.
Job 2 will execute before Job1. because it has a higher priority number (9) than Job1. VENU.CLASS=8.CLASS=8. PRTY=6 JOB (A123).EXAMPLE :
//JOB1 //JOB2 JOB (A123). VENU.
. • First. • The MSGCLASS parameter determines the output device to which. there are those related to the system and the JCL.‘MSGCLASS’ PARAMETER
Messages can be categorized into two types. system messages and JCL messages are written. there are those that are output by the program or procedure being executed.
The output-class-name is related to a specific output device to which messages are routed.
MSGCLASS=output-class-name Where output-class-name can be any alphabet (A-Z) or number (0-9).
VENU is the author. CLASS=K. priority is set to 6.
JOB1 is the jobname. and MSGCLASS is A. MSGCLASS=A.
.PRTY=6.EXAMPLE 1 : //JOB1 JOB (A123). VENU. JOB is the keyword identifying the JOB statement. (A123) is the account number.
.VENU.CLASS=K.EXAMPLE 2 : //JOB1 JOB (A123). which could specify a printer or any other output device. MSGCLASS=1 The message class is set to 1.
. many kinds of messages are generated by the system.
. As a JCL job is submitted. log messages indicating job name. These messages can be categorized as follows : • First. user name.
Contd.. are routed to the output device. The MSGLEVEL parameter is used to specify the JCL and the
allocation messages which will be recorded on the output device specified in the message class. etc.
• Next. • Finally.. • Messages related to the execution of the job are output.‘MSGLEVEL’ PARAMETER (Contd. the output of the program being executed is output. JCL statements comprising that job are output.
MSGLEVEL = (statements. and messages is a value which can be 0 or 1.
Contd…. STATEMENTS: Coding a 0 in statements will result in messages related to the job statement only being output. or 2.messages) Where statements may be the number 0. messages) Or MSGLEVEL = statements or MSGLEVEL = (.
Coding a 2 will result in only the input JCL statements being printed. if any cataloged procedures are invoked.
Coding a 1 will result in all JCL in the job being submitted being output. MESSAGES: In the messages field. regardless of whether the job terminates normally or abnormally. Coding a 1 will result in all allocation messages being output. 0 or 1 can be coded. In addition to this.. Coding a 0 will result in all allocation messages being output if the job terminates abnormally.SYNTAX (Contd. then their JCL will also be output.
.MSGLEVEL = 0 Only the JOB statement will be printed.1) MSGLEVEL is set to (1.EXAMPLE 1 :
//JOB1 JOB (A123).‘JAI’.MSGLEVEL=(1. All JCL statements will be printed. including allocation messages.
EXAMPLE 2 :
//JOB1 JOB (A123).‘JAI’.
.‘ TYPRUN’ PARAMETER
or it is to be scanned for syntax errors.
TYPRUN=HOLD Or TYPRUN=SCAN
Used to specify whether a job is to be held until it is released.
Specification of the SCAN parameter results in the job being scanned for syntax errors and reports them to the requested output media
Specification of HOLD parameter results in the job being held until further notice. Useful when jobs which utilize a lot of resources are to be held until a time when the system is relatively unused..‘ TYPRUN’ PARAMETER (Contd.
EXAMPLE 2 :
//JOB2 JOB (A123).TYPRUN=HOLD
JOB1 will be held until it is released by the operator.‘JAI’.EXAMPLE 1 :
//JOB1 JOB (A123).TYPRUN=SCAN
The JCL will be checked for syntax errors.
//JOB10 JOB NOTIFY=JB007 User JB007 will be notified when the job finishes.
The NOTIFY parameter on the JOB statement automatically notifies the specified user when the job is completed.
priority 9 and message class =A. accounting information is NTP4.CLASSROOM EXERCISE . author name is Your name.Class is Z.I
Write a JOB statement wherein JOB name is JOB3.
class is A. priority is 10 and typrun = scan. message level is default. accounting information is A123.II
Write a Job statement wherein job name is JOB1. message class is B.
.CLASSROOM EXERCISE .
To understand • EXEC statement • Positional parameters and Key word parameters • The following parameters coded on the EXEC statement PGM ADDRSPC RD • ACCT DPRTY PARM PERFORM
JOBLIB and STEPLIB statements
To try and solve the classroom exercises
it can be the execution of a procedure that is pre-written and available for general use by users of the system. • A Job Step is a unit of work that is submitted to the operating system in the form of collection of JCL statements.
. • A unit of work can be the execution of a program or.‘ ‘EXEC’ STATEMENT
The EXEC statement is the first statement of each job step.
//stepname EXEC PGM=program-name. EXEC is the operation. keyword parameters where stepname is the name assigned to the job step. program-name is the name of the program ( this is a positional parameter ) and keyword parameters follow the positional parameter
No special syntax is required for this parameter.
The STEPNAME is used to give unique and meaningful
names to each step. PROGRAM1 is being executed.PGM is the positional parameter.
//STEP01 EXEC PGM=PROGRAM1 STEP01 is the name of the step. EXEC is coded in the operation field.
• When it is required to use a restart parameter.
• When it is necessary to reference a previously executed job step.Conditions In Which Stepname Is Mandatory. Restart parameter helps to restart the job from the step that failed and avoids restarting the entire job consisting several job steps. • When an overriding parameter is used.
that is : PGM parameter. • There is only one positional parameter in the EXEC statement.
.POSITIONAL PARAMETERS OF THE EXEC STATEMENT
• Positional parameters are characterized by the order in which they appear. and they must precede keyword parameter.
//stepname EXEC PGM=program-name
• The PGM parameter identifies the name of the program that is
to be executed.
• Keyword parameters used in EXEC statement are : ACCT parameter ADDRSPC parameter PERFORM parameter PARM parameter DPRTY parameter RD parameter
.KEYWORD PARAMETERS OF THE EXEC STATEMENT
• The keyword parameters coded for a job step will apply only to that step. • Keyword parameters can be coded in any sequence.
The ACCT parameter is used to supply accounting
information for the job step that it is used in.‘ACCT’ PARAMETER
..) Or ACCT=account-information account-information consists of one or more subparameters defined by installation..
The accounting information that follows the ACCT parameter is specific to this job step only.
//STEP2 EXEC PGM=PROGRAM2. EXEC is the operation. ACCT=(A123.EXAMPLE 1:
//STEP1 EXEC PGM=PROGRAM1. PROGRAM1 is being executed.ACCT=A123
STEP1 is the stepname.
EXAMPLE 1 : //STEP1 EXEC PGM=PROGRAM1.PARM=PRINT
PROGRAM1 is executed. SYNTAX PARM=value Where value is a string from 1 to 100 characters long.
• The PARM parameter is used to supply information to a program
as it executes. and the string “PRINT” is supplied to it during execution.
.EXAMPLE 2 :
//STEP2 EXEC PGM=PROGRAM2. The apostrophes are not passed to the program as part of the string. and therefore the string is enclosed in apostrophes.PARM=‘13+10’
A special character (+) is included in the string.
‘JOBLIB’ AND ‘STEPLIB’ STATEMENTS
• It is not enough to know the name of the program that is to be executed.
. Its location in the system has to be specified by the JOBLIB or STEPLIB statements. It is essential to know where that program resides.
• The EXEC statement identifies the member name only.
and it specifies where the program that is specified by the EXEC statement resides.‘JOBLIB’ STATEMENT
• The JOBLIB statement immediately follows the JOB statement. DISP=SHR //STEP1 EXEC PGM=PROGRAM1 JOBLIB DD statement is used to specify the location of the program that is to be executed.
• It is a DD (Data Definition ) statement .TEST.
EXAMPLE 1 :
//JOB1 JOB (A123).‘JAI’ //JOBLIB DD DSN=M1.LOADLIB.TEST. Program1 is a member of the partitioned dataset M1.
.‘JAI’ //JOBLIB DD DSN=M1.LOADLIB.TEST. DISP=SHR //STEP1 EXEC PGM=PROGRAM1 //STEP2 EXEC PGM=PROGRAM2 Both PROGRAM1 and PROGRAM2 exist in the library called M1.TEST.LOADLIB.EXAMPLE 2 :
//JOB1 JOB (1234).
// DISP=SHR. // VOL=SER=PACK1 The UNIT and VOL parameters are used because PROGRAM3 is uncataloged. // UNIT=3321. JOBLIB
.EXAMPLE 3 :
//JOB2 JOB (A123).‘VENU’ //JOBLIB DD DSN=PROGRAM3.
• The function of the STEPLIB statement is the same as the JOBLIB
statement. EXAMPLE : //JOB1 //STEP1 //STEPLIB //STEP2 //STEPLIB JOB EXEC DD EXEC DD (1234).LOADLIB1 and program2 is a member in the PROD.‘VENU’ PGM=PROGRAM1 DSN=PROD.LOADLIB2. DISP=SHR
Program1 is a member in the PROD. • Is effective only for that jobstep. This statement is coded after the EXEC statement . instead of the entire job.
. DISP=SHR PGM=PROGRAM2 DSN=PROD.LOADLIB2.
CODING BOTH ‘JOBLIB’ AND ‘STEPLIB’ STATEMENTS
• If both the JOBLIB and STEPLIB statements are coded.
. then it is good practice to code the JOBLIB statement. • If the same library is used for all jobsteps. then the STEPLIB specification will override that of the JOBLIB for that jobstep • The specification of the JOBLIB will continue for any jobstep that does not have a corresponding STEPLIB statement.
LOADLIB.‘VENU’ CLASS=0 MSGCLASS=T DSN=A100. DISP=SHR PGM=PROGRAM1 DSN=B100.LOADLIB.TEST.. TEST. DISP=SHR PGM=PROGRAM2 PGM=PROGRAM3 DSN=C100.LOADLIB.EXAMPLE :
//JOB1 // // //JOBLIB // //STEP1 //STEPLIB // //STEP2 //STEP3 //STEPLIB // // JOB (1234). DISP=SHR
DD EXEC DD EXEC EXEC DD
then the job step is locked into real storage only.
. • Virtual storage results in program addresses being independent of the addresses that actually exist in the computer. • If ADDRSPC is set to REAL. • Setting the ADDRSPC to VIRT results in that job step being paged.‘ADDRSPC’ PARAMETER
• The purpose of this parameter is to indicate to the system that
the job should use either virtual or real storage.
. and REAL indicates real storage only.SYNTAX
ADDRSPC=REAL Or ADDRSPC=VIRT VIRT indicates virtual storage. If ADDRSPC is omitted. virtual is the default.
. and will not be paged. // ADDRSPC=REAL PROGRAM 2 will utilize real storage only. // ADDRSPC=VIRT Program1 will be paged. EXAMPLE 2 : //JOB2 EXEC PGM=PROGRAM2.EXAMPLE 1 :
//JOB1 EXEC PGM=PROGRAM1.
Class assigns a priority to the job.
• Used to assign Dispatching Priority to the job step.
• Dispatching priority is used by the system to determine the order in which tasks are to be executed. and DPRTY assigns a priority to the job step. • Dispatching priority is different from class priority.
Value 2 ranges from 0 to 15. DPRTY is computed as follows: DPRTY=(value1)*(16)+ value2
. higher the priority. Higher the number.SYNTAX DPRTY=(value1.value2) Where value1 ranges from 0 to 15 and specifies the priority of the job step.
The priority in step1 is determined as : ( 12 * 16 ) + 9 = 192 + 9 = 201
.‘VENU’ //STEP1 EXEC PGM=PROGRAM1.EXAMPLE :
JOB (A123). // DPRTY=(12.
• A Performance Group determines the rate at which the job steps in a job have access to system resources and is helpful in optimizing system performance.
PERFORM=n where n ranges from 1 to 999.‘PERFORM’ PARAMETER
• The PERFORM parameter is used to specify the Performance
Group for the job step.
. ‘VENU’ //STEP1 EXEC PGM=PROGRAM1. The number 10 will be installation defined. // PERFORM=10 STEP1 is assigned the performance group10.EXAMPLE :
//JOB1 JOB (A123).
• It also fully or partially suppresses the CHKPT (Checkpoint) macro instruction.
. • Checkpoints enable to restart a job from the last successful checkpoint rather than from the beginning of the run .‘RD’ PARAMETER
• The RD ( Restart Definition) is used to specify automatic restart of a job if it abends. so that no checkpoints are taken as a program executes. • A Checkpoint is taken by the system to record the status of a program as it executes.
RD=R Or RD=RNC Or RD=NR Or RD=NC Where R RNC NR NC for restart for restart with No Checkpoint for No Automatic Restart for No Checkpoint.
.EXAMPLE 1 :
//JOB1 JOB (A123). // RD=R
The operator can perform automatic step restart if the job abends. ‘VENU’ //STEP1 EXEC PGM=PROGRAM1. The checkpoint macro is not suppressed.
‘VENU’ //STEP2 EXEC PGM=PROGRAM2.EXAMPLE 2:
//JOB2 JOB (B123). Checkpoints are suppressed. // RD=RNC
The operator can perform automatic step restart if the job step fails.
Write a JCL with job name JOB1 . STEP3---------WRITE Step4--------.COB3.COB1. COBOL2 is in TRNG.PRINT.NTP4. Step1 is executing program COBOL1.NTP4.NTP4. Step2-------. COBOL3 and COBOL4 lie in TRNG. COBOL1 resides on TRNG. Step3 executes COBOL3 and Step4 executes COBOL4. consisting of 4 steps.COB2.SAVE
. The PARM parameters associated are Step1 ------. Step2 executes COBOL2.READ.
To try and solve classroom exercises. REGION COND TIME • The DD statement • Concept of Temporary datasets and Permanent datasets.OBJECTIVES
To understand • The usage of following additional parameters coded on both JOB and EXEC statement. • DSN parameter coded on the DD statement.
REGION=value1K Or REGION=value2M Where value1 is the storage in multiples of 1024 bytes. The K and M must follow value1 and value2. and value2 is storage in multiples of one million bytes.‘REGION’ PARAMETER
At the time that a job is run.
. a default amount of work space is automatically assigned to it. This default can be overriden via the REGION parameter.
// REGION=96K REGION parameter is coded in the EXEC statement. and is used to specify that this job step can utilize 96 thousand bytes of storage. ‘VENU’ //STEP1 EXEC PGM=PROGRAM1.
.EXAMPLE 1 :
//JOB1 JOB (A123).
REGION parameter is in the EXEC statement and is set to 88K.‘VENU’ REGION=88K
//STEP1 EXEC PGM=PROGRAM1.EXAMPLE 2 :
//JOB1 // JOB (A1230).
// REGION=3M //STEP1 EXEC PGM=PROGRAM3
REGION is coded on the JOB statement.‘VENU’.
. The system will allocate 3 million bytes of storage for job3.EXAMPLE 3:
//JOB3 JOB (A123).
‘REGION’ CODED ON THE JOB STATEMENT
Usually the system will provide a default region size in which the job is to execute. If enough storage space is not specified the job will terminate abnormally. However this can be overriden by using the REGION parameter coded on the JOB statement.
.If enough storage is not specified the job will abend .
‘REGION’ CODED ON THE EXEC STATEMENT
The REGION parameter coded on an EXEC statement requests storage only for that individual job step.
condition) Where comparison-code is a number between 0 and 4095. and it overrides COND parameters coded on the EXEC statement.
.‘COND’ CODED IN THE JOB STATEMENT
A COND parameter coded on the JOB statement applies to all job steps within the job. and the return code of the prior step. if they exist. and condition specifies the type of comparison to be made between the comparison-code that has been coded.
execution of subsequent job steps is halted.SOME COMMON CONDITION CODES
Return Code 0 Explanation Implies successful execution of job step Implies warning messages have been issued for the job step Implies serious error in job step Implies fatal error.
Bypass current step if comparision-code is less than return code. Bypass current step if comparision-code is greater than or equal to return code.
.OPERATORS CODED ON THE ‘COND’ PARAMETER
Operator GT GE LT
Explanation Bypass current step if comparision-code is greater than the return code.
. Bypass current step if comparison-code is not equal to return code..)
Operator LE EQ NE
Explanation Bypass current step if comparison-code is less than or equal to return code. Bypass current step if comparison-code is equal to return code.OPERATORS CODED ON THE ‘COND’ PARAMETER (Contd.
//JOB1 // //STEP1 //STEP2 //STEP3 JOB (A123).
.LT) EXEC PGM=PROGRAM1 EXEC PGM=PROGRAM2 EXEC PGM=PROGRAM3
If a condition code less than 4 is returned at any step then the subsequent steps would not be executed. COND=(4.
‘COND’ CODED IN THE EXEC STATEMENT
The condition parameter coded on the EXEC statement applies only to the Job Step that it is coded in.
This job step is executed or bypassed. depending on the return codes returned by one or more prior job steps.
condition.condition) or COND=(comparison-code..
.) or COND=EVEN or COND=ONLY Comparison-code ranges between 0 and 4095.condition specifies the type of comparison to be made between the comparison-code that has been coded..SYNTAX
COND=(comparison-code... and the return code of the prior step. stepname. Contd..
• Step name specifies the name of the preceding step whose
return code is to be checked.
• The keyword ONLY is used to specify that the step in which
it is specified is to be executed only if any of the prior steps terminate abnormally.
//JOB1 JOB (A123).‘VENU’ //STEP1 EXEC PGM=PROGRAM1 //STEP2 EXEC PGM=PROGRAM2.STEP1)
The COND parameter is used to specify that step2 should be bypassed if 8 is equal to the return code issued by step1.EQ. // COND=(8.
then the installation defined TIME parameter is used.‘TIME’ PARAMETER
• This is an optional keyword parameter and is used to specify the amount of CPU Time that a job or step is permitted to utilize before it is terminated. • When coded in the EXEC statement. it specifies the amount of CPU time that the JOB is allowed to use. • If the TIME parameter is not specified.
. • CPU Time is the time that a job takes to execute. • When coded in the JOB statement. it specifies the amount of CPU time that the job step is allowed to use.
//JOB1 JOB (A123). //STEP1 EXEC PGM=PROGRAM1.
.seconds) or TIME=(.SYNTAX
TIME=(minutes) or TIME=(minutes. // TIME=5 5 minutes of CPU time is assigned to STEP1.
then the TIME parameter on the EXEC statement will override the TIME parameter on the JOB statement .‘TIME’ Coded On Both JOB Statement And EXEC Statement
• If the TIME parameter is coded on both the JOB and EXEC
COB3 and COBOL4 is in TRNG. COBOL4 must be executed only if COBOL3 has terminated normally.CLASSROOM EXERCISE
Write a JCL where job name is JOB1.NTP4. Region for COBOL2 is 40K and CPU time is 10 min.
. COBOL3 is in TRNG.NTP4. COBOL3.COB. COBOL4.programs to be executed are COBOL1.NTP4.COB4. COBOL1 and COBOL2 are in TRNG. COBOL2.
‘DD’ ( DATA DEFINITION ) STATEMENT
• The data definition statement is used to identify the source of input and the placement of output information. Passed to subsequent job steps.
. Cataloged. Kept. the data can be:
• • • • •
On successful execution of a job. Uncataloged.
Name dd name
Parameters Operands <positional/ keyword parameters>
• Each ddname should be unique within the jobstep.
• As a job executes.
//JOB1 JOB A123. the system performs device and space allocations for each ddname specified.‘DD’ NAME
• The ddname identifies the name of the data definition
statement.’VENU’ //STEP1 EXEC PGM=PROGRAM1 //NAME1 DD DSN=DATA1 NAME1 is the DD name.
DD NAMES RESERVED FOR THE SYSTEM USE
The following names are reserved for the system use and may not be used to define DD statements: //JOBLIB //SYSABEND //SYSCHK //STEPCAT //SYSOUT //SYSDBOUT
//JOBCAT //SYSIN //STEPLIB //SYSUDUMP //SYSOUD
It is used to specify the name of the data set to the operating system.‘DSN’ PARAMETER
• The DSN parameter is a keyword parameter on the DD
DSN=data-set-name Where data-set-name can be qualified or non-qualified.
• Qualified names consist of two or more non-qualified names. • Qualification results in the location of the data set being easily identified by its name.
. each separated from the next by a period . The first name is called the highest qualifier of that name.
//JOB1 JOB A123.GROUP2.‘VENU’ //STEP1 EXEC PGM=PROGRAM1 // DD DSN=PROJECT1.DATA(TEST1)
• The system assigns a unique name to it. and reference is made to it by referencing the stepname and ddname.
. This is called a refer back.TEMPORARY DATA SETS
• A temporary data set is created during a job execution and deleted after job completion. • A temporary data set is recognized as such if the DSN parameter is omitted.
.‘VENU’ EXEC PGM=PROGRAM1 DD EXEC PGM=PROGRAM2 DD *. created in STEP1 is referenced via referback. Step2 executes PROGRAM2 and the temporary data set DATA1.EXAMPLE 1:
//JOB1 //STEP1 //DATA1 //STEP2 //DATA2 JOB A123. * indicates a referback.DATA1
Step1 executes PROGRAM1 and a data set DATA1 is created in the next statement.STEP1.
EXAMPLE 2 :
//JOB1 JOB A123.
.• A temporary data set is also recognized by starting the dataset
name with two ampersands in the DSN parameter .‘VENU’ //STEP1 EXEC PGM=PROGRAM1 //DATA1 DD DSN=&&ABCD Here ABCD is prefixed with two ampersands and is a temporary dataset.
EXAMPLE : //JOB1 //STEP1 //DATA1 JOB A123.‘VENU’ EXEC PGM=PROGRAM1 DD DSN=MIS.PERMANENT DATA SETS
• A permanent data set is not deleted after a job is completed and may be cataloged.PROJECT. • It is coded by setting a DSN parameter that is equal to a qualified or non-qualified name. if requested.
Use refer back technique.NTP4.COB. A temporary dataset NTP is created by step1 and is used by step2.
Write a JCL where job name is JOB1. Two programs COBOL1 and COBOL2 are executed and they are in TRNG.
DISP UNIT To interpret the examples using the above parameters and their sub-parameters.
. To try and solve the classroom exercises.OBJECTIVES
To understand • The following parameters and their sub-parameters coded on the DD statement.
used to instruct the system as to the current status of a data set. and the steps to be taken with the data set upon normal and abnormal termination of the job..
• The status field indicates the current status of the data set i.
• DISP is a keyword parameter..e whether it exists or has to be created.normal-disposition.
.e whether to be used exclusively . • The normal disposition subparameter specifies how the data set is to be disposed upon normal execution of the job. • The abnormal-disposition subparameter specifies how the data set is to be disposed upon abnormal execution of the job.SYNTAX (Contd. or if it can be shared by other jobs in execution.
• If the data set exists the mode of access is to be specified i.
SUB-PARAMETERS ON ‘DISP’PARAMETER
Status NEW OLD MOD SHR
Normal disposition DELETE KEEP CATLG UNCATLG PASS
Abnormal disposition DELETE KEEP UNCATLG CATLG
. such as disk then the UNIT and SPACE parameters must also be coded. • NEW is also the default. if nothing is coded in the status field. • If the data set is to reside on a direct access volume.‘NEW’ SUB-PARAMETER
• Coding DISP= NEW indicates that a new data set is to be created.
JCL.GROUP1.‘VENU’ //STEP1 EXEC PGM=PROGRAM1 //DATA DD DSN=PROJECT1. The next statement utilizes the DISP parameter to inform the operating system that this is a new data set
//JOB1 JOB A123. // DISP=NEW Program1 is executed and the data set is created.(TESTDATA).
‘VENU’ //STEP1 EXEC PGM=PROGRAM1 //DATA DD DSN= PROJECT1.
//JOB1 JOB A123.GROUP1.JCL(TESTDATA). // DISP=OLD
. • The data set becomes available exclusively to the step in which it is referenced.‘OLD’ SUB-PARAMETER
• Coding OLD in the status field results in the operating system searching for an existing data set with the name specified in the DSN parameter.
so that records can be added to it easily. then the system replaces MOD with NEW.‘MOD’ SUB-PARAMETER
• The MOD subparameter is used to modify sequential data sets. use of the MOD subparameter results in the reader/writer of the device positioning itself just after the last record. • If the data set already exists. and creates it.
The MOD parameter does the following things :
• If the sequential data set does not exist.
//JOB1 JOB A123.‘VENU’ //STEP1 EXEC PGM=PROGRAM1 //INPUT1 DD DSN=USER1.JCL.SHR SUB-PARAMETER
• Setting DISP=SHR allows multiple jobs to read the same data set
which already exists.GROUP1.NAMEFILE // DISP=SHR
COBOL1 creates a new permanent dataset which will reside in TRNG.CLASSROOM EXERCISE
Write a JCL where job name is JOB1 and two programs COBOL1 and COBOL2 are being executed.NTP4.DATA1 and it is referred by COBOL2.NTP4.
. Both the programs reside in TRNG.
normal-disposition. SYNTAX DISP=(status.NORMAL-DISPOSITION FIELD
• The normal disposition field in the DISP parameter is used to
indicate what to do with the data set upon normal termination of the job.abnormal-disposition) The sub-parameters that can be coded here are : DELETE KEEP CATLG UNCATLG PASS
• The delete sub-parameter indicates that the data set being
referred is to be deleted after the successful termination of the job.
//JOB1 JOB A123. // DISP=(OLD.‘VENU’ //STEP1 EXEC PGM=PROGRAM1 //NAME1 DD DSN=TEMPFILE.DELETE) TEMPFILE is a pre-existing data set that is deleted upon the successful termination of the job JOB1.
. • This parameter should be used with permanent data sets.‘KEEP’ SUB-PARAMETER
• The KEEP subparameter indicates that the data set is to be retained or kept upon successful execution of the job.KEEP) A permanent data set called BOOKS is retrieved and kept after it has been read.
//JOB1 JOB A123.‘VENU’ //STEP1 EXEC PGM=PROGRAM1 //NAME1 DD DSN=BOOKS. // DISP=(OLD.
and volume are recorded. • Temporary data sets can never be cataloged. they can only be passed to the next step using the PASS subparameter.‘CATLG’ SUB-PARAMETER
• The CATLG subparameter is used to specify that the data set is to be retained and recorded in the system catalogs after successful termination of the job. unit.
. • The data set name.
EXAMPLE : //JOB1 JOB //STEP1 EXEC //NAME1 DD // A123.OUTPUT.UNCATLG)
The pre-existing data set. If the data set is not found the job terminates abnormally.OUTPUT. is removed from the system catalogs. called DISK. DISP=(OLD.‘UNCATLG’ SUB-PARAMETER
• The UNCATLG subparameter is used to remove the entry of the data set from the system catalogs.‘VENU’ PGM=PROGRAM1 DSN=DISK. • The data set itself is not deleted.
Setting DISP to PASS specifies that the data set is to be passed to a subsequent job step within the same job.
• The data set will continue to be passed to subsequent steps, if it is not utilized by any intervening job steps. • The data set can be used by any subsequent step. • Both temporary and permanent data sets can be passed to subsequent steps. • Data from a prior step can be referenced by its name, or by the referback syntax. • If this subparameter is used with tape data sets, then the tapes remain mounted between job step.
EXAMPLE 1 :
//JOB1 JOB (K123),‘JAI’ //STEP1 EXEC PGM=PROGRAM1 //DATA1 DD DSN=FILE1, DISP=(NEW,PASS) //STEP2 EXEC PGM= PROGRAM2 //DATA2 DD DSN=FILE1, DISP=(OLD,DELETE) PROGRAM1 creates a new dataset called FILE1. The DISP parameter is used to pass it on to subsequent steps within that job. In STEP2, FILE1 which is passed from the prior step is accessed. Hence the DISP parameter is : DISP=(OLD,DELETE)
EXAMPLE 2 :
//JOB1 JOB (K123),‘JAI’ //STEP1 EXEC PGM=PROGRAM1 //DATA1 DD DSN=FILE1, DISP=(NEW,PASS) //STEP2 EXEC PGM= PROGRAM2 //DATA2 DD DSN=*.STEP1.DATA1, DISP=(OLD,DELETE) Data passed from STEP1 is accessed in STEP2 via Referback. Referback follows the following syntax : DSN=*.stepname.ddname Where ‘*’ is required, stepname is the name of the step, and ddname is the DD statement name.
EXAMPLE 3 :
//JOB1 JOB //STEP1 EXEC //DATA1 DD // //STEP2 EXEC //DATA2 DD // (K123),‘JAI’ PGM=PROGRAM1 DSN=&&XYZ, DISP=(NEW,PASS) PGM= PROGRAM2 DSN=*.STEP1.DATA1, DISP=(OLD,DELETE)
The Refer back method is used to access the temporary dataset &&XYZ, which was created in STEP1.
Write a JCL where job name is JOB1 and two programs P1 and P2 are executed. A PDS is created by P1 and is exclusively used and should be retained on normal termination of the job.
• This subparameter is required only if the abnormal disposition is different from the normal disposition.abnormal-disposition) The following subparameters can be used in this field : DELETE KEEP UNCATLG CATLG The description of each of the above parameters remain the same except that now they refer to abnormal termination of the job.ABNORMAL-DISPOSITION FIELD
• The abnormal disposition field tells the system what to do with the data set upon abnormal termination of the job.
EXAMPLE 1 :
//JOB1 //STEP1 //DATA1 // JOB A123. the system is informed that it should be cataloged.CATLG. If the job terminates successfully. If the job terminates unsuccessfully.DELETE)
The dataset called FILE1. is created.
. DISP=(NEW. the system is instructed to delete it.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.
the system is instructed to retain the dataset.KEEP)
A new dataset FILE1 is created and on successful termination of the job the system is instructed to catalog it.CATLG. but not to catalog it. Upon unsuccessful termination.EXAMPLE 2 :
//JOB1 //STEP1 //DATA1 // JOB A123. DISP=(NEW.
.‘JAI’ EXEC PGM=PROGRAM2 DD DSN=FILE1.
EXAMPLE 3 :
//JOB1 //STEP1 //DATA1 // JOB A123.CATLG. it is to be deleted.‘JAI’ EXEC PGM=PROGRAM3 DD DSN=FILE1. this dataset is to be cataloged.
. Upon successful termination of the job. Upon unsuccessful termination of the job.DELETE)
The system is informed that FILE1 is a old data set. DISP=(OLD.
Write a JCL where job name is JOB1 and two programs P1 and P2 are executed . This PDS should be referred back by step 2 where in program P2 is executed. A PDS is created as a result of the execution of program P1 and should be cataloged on normal termination of the job and should be deleted on abnormal termination of the job.
• The abnormal disposition field defaults to the same value as the
normal disposition field.‘DISP’ DEFAULTS
• The status field defaults to NEW • If the status is NEW the default for normal disposition is
DELETE and if the status is old the default for normal disposition is KEEP.
• The LABEL parameter is used to specify information specific to tape datasets.
.‘UNIT’. ‘VOL’ AND ‘LABEL’ PARAMETERS
• The DD statement is used to supply the input and output
information to the operating system.
• The UNIT parameter is coded on the DD statement to specify an input or output device that is to be accessed. • The VOL parameter is also coded on the DD statement to identify specific disk tape volume(s).
. The following characteristics can be used to identify them to the operating system:
• All devices have an address assigned to them at the time that they are added to the system.‘UNIT’ PARAMETER
INTRODUCTION In an IBM mainframe environment. • Device can be distinguished by a number which indicates the numeric model... Devices can be referenced via this address. Contd. input and output devices can be categorized in different ways.
• If a device is specified in one job step.. and the group given a name..‘UNIT’ PARAMETER (Contd. Devices can be referenced via group name.)
• Certain types of devices can be grouped together. then a subsequent step may request the same device by referencing the ddname of the DD statement in which the unit was originally specified.
defer) device. until it is ready to be used
.JCL PARAMETERS USED IN ‘UNIT’
CORRESPONDING JCL FUNCTION PARAMETERS AND SUBPARAMETER Specification of device via address UNIT=device-address Specification of device by model UNIT=device-type type Specification of device as part of a UNIT=group-name group Specification of device used by a UNIT=AFF previous job step Deferring the mounting of a tape UNIT=(device.
The general syntax for the UNIT parameter is : UNIT=device-address UNIT=device-type UNIT=device-group-name UNIT=AFF=prior-ddname UNIT=(device.DEFER)
SPECIFICATION OF DEVICE ADDRESS
• Each I/O device attached to a computer is assigned a hardware address when a system is generated • Device addresses are expressed as three hexadecimal digits. Unit parameter
. is accessed.‘JAI’ //STEP1 EXEC PROGRAM1 //DATA1 DD DSN=FILE1. // UNIT=A04 A dataset called FILE1.
//JOB1 JOB A123. which resides on a device identified by its hardware address A04.
which resides on a 3380 disk unit.‘JAI’ //STEP1 EXEC PROGRAM2 //DATA1 DD DSN=FILE2. A dataset called FILE2.
EXAMPLE: //JOB1 JOB A123.
.SPECIFICATION OF DEVICE TYPE
• A device type is identified by the model number assigned to that device by IBM. one needs to know the devices that are being used by the installation. • In order to code the device type on the UNIT parameter. // UNIT=3380. is accessed.
• Devices are often grouped together based on their function. SYSDA is traditionally assigned to direct access storage devices.
.SPECIFICATION OF DEVICE GROUP
• A device group name is a symbolic name which is assigned to a group of devices when the system is generated.
‘JAI’ PROGRAM3 DSN=FILE3.
A data set called FILE3 resides on any of the devices which are grouped under the symbolic name SYSDA.EXAMPLE :
//JOB1 JOB //STEP1 EXEC //DATA1 DD // A123.
Write a JCL where job name is JOB1 which executes a program P1 and creates a dataset called ABC on unit 3380.
specified in a prior DD statement.‘AFF’ SUB-PARAMETER
• The AFF subparameter can be used to reference a device. ddname2 is the name of the DD statement in which the AFF parameter is used to reference the prior DD statement. that is same unit is reused.
. AFF stands for affinity.
• This kind of specification results in unit affinity.
//ddname1 DD UNIT=TAPE //ddname2 DD UNIT=AFF=ddname1 ddname1 is the name of the DD statement in which the device for the UNIT parameter was originally specified .
.‘JAI’ PGM=PROGRAM1 DSN=DATA1.EXAMPLE 1 :
//JOB1 JOB //STEP1 EXEC //NAME1 DD // //NAME2 DD // A123. UNIT=CART DSN=DATA2. UNIT=AFF=NAME1
AFF subparameter is used to specify that the data set called DATA2 must reside on the same unit as that specified in NAME1.
• If the defer parameter is encountered for a volume that is already mounted .‘DEFER’ SUB-PARAMETER
• The DEFER subparameter is coded on the UNIT parameter so that it may defer mounting of the volume that it references. • It prevents volumes from being mounted until they are actually needed. thereby freeing up resources for other jobs. until the data set that resides on it is opened.
. then it is simply ignored.
The device count subparameter identifies the number of tapes required for the job.SYNTAX
//ddname DD UNIT=(device.DEFER)
The extra comma in the middle is used to specify the device count subparameter.
‘VENU’ PGM=PROGRAM1 DSN=DATA1. and that the tape need not be mounted until the system specifically requests it.DEFER)
DEFER parameter is used to specify that DATA1 resides on tape. This request will be issued by the system at the time that JOB1 is executed and PROGRAM1 requires access to DATA1.EXAMPLE :
//JOB1 JOB //STEP1 EXEC //NAME1 DD // C123. UNIT=(TAPE.
. To try and solve the classroom exercises.OBJECTIVES
To understand • The following parameters and their sub-parameters coded on the DD statement. VOL SPACE DCB To interpret the examples using the above parameters and their sub-parameters.
• This parameter is used to identify the volume serial number of the device on which a given data set is to be written or on which a dataset resides.
. VOL or VOLUME can be used interchangeably on the DD statement.‘VOL’ PARAMETER
• The VOL parameter is also coded on the DD statement and is used to identify specific tape(s) or disk volume(s).
Position Within A JCL Statement
.‘VOL’ PARAMETER (Contd.
CORRESPONDING JCL PARAMETERS
FUNCTION SUBPARAMETERS CODED ON THE VOL STATEMENT.
. PRIVATE SEQ
Specification of serial number Referencing VOL specification Allowing acces to volume by all users Inhibiting dismounting of volume by single user Specification of sequence in which volumes are to be mounted. unless coded otherwise. SER REF This is the default.
TYPES OF LABELS
• This contains the volume serial number.
DATA SET LABEL
• Data set labels are found at the beginning and at the end of tape data sets. • They consist of 80 byte records that contain information for the data set. and is used for identification purposes by the system.
. • Both types of labels reside on the volume itself as data.
TYPES OF VOLUMES
Volumes can be classified by the type of access available to the users . They can be categorized as follows:
These are accessible to a single user only. Tapes are always private.
These are accessible to all users.
• The SER subparameter coded on VOL in the DD statement is used to request specific volumes. Or VOL=SER=(serial number1.
VOL=SER=serial number. serial number2)
DATA1 is accessed on a volume whose serial number is 23456
//JOB1 JOB //STEP1 EXEC //NAME1 DD // A123.‘VENU’ PGM=PROGRAM1 DSN=DATA1.
The REF subparameter is a shortcut method used to specify a volume which has been previously defined within the same job.
‘VENU’ EXEC PGM=PROGRAM1 DD DSN=DATA1. VOL=SER=VOL1 DD DSN=DATA2.STEP1.EXAMPLE :
//JOB1 //STEP1 //NAME1 // //NAME2 // JOB A123.NAME1
‘VENU’ PGM=PROGRAM1 DSN=DATA1.. VOL=(PRIVATE..
//JOB1 JOB //STEP1 EXEC //NAME1 DD // A123..‘PRIVATE’ SUB-PARAMETER
• Coding PRIVATE on the VOL parameter results in exclusive
use of the volume for the data set specified in the job step. This means that only one job can access it at a time.SER=23456)
• The RETAIN sub parameter is used to indicate that the volume is not to be dismounted after completion of the job step that it is coded in.The volume remains mounted until the entire job is completed...RETAIN.RETAIN) Or VOL=(.
..‘VENU’ PGM=PROGRAM1 DSN=DATA1.RETAIN. VOL=(.EXAMPLE :
//JOB1 JOB //STEP1 EXEC //NAME1 DD // A123.
.‘SEQ’ (SEQUENCE) SUB-PARAMETER
• The sequence subparameter is used to specify the sequence number of the volume that is to be mounted for a particular step.)
.sequence-number.. .sequence-number) Or VOL=(.
SYNTAX VOL=(. .Like PRIVATE and RETAIN it is a positional parameter..
. VOL=SER=HUGE EXEC PGM=PROGRAM2 DD DSN=DATA2 VOL=(. .A125.‘VENU’ EXEC PGM=PROGRAM1 DD DSN=DATA1..A127)
STEP1 executes PROGRAM1 and the dataset called DATA1 is accessed on the volume whose serial number is HUGE.A124.EXAMPLE :
//JOB1 //STEP1 //NAME1 // //STEP2 //NAME2 // JOB A123.A126. In STEP2 the VOL parameter is used to specify that processing should start at volume 3 of a multivolume dataset DATA2. processing starts at volume 1.SER=A123. is supplied at position 3.3.Since no sequence no.
A dataset ABC is created as a result of the execution of program P1.
Write a JCL where job name is JOB1 and two programs P1 and P2 are executed . This is created on unit 3380 Volume serial number
234 with sequence no starting at 5 and ending at 10.
‘SPACE’ AND ‘DCB’ PARAMETERS
• The SPACE and DCB parameters are coded on the DD statement. • The SPACE parameter is used to allocate storage for new data sets on direct access storage devices. • The DCB parameter is used to customize the way data is stored on devices.
• It is an optional keyword parameter on the DD statement.
CONTIG.ROUND) OR SPACE=(TRK(primary.ROUND) OR SPACE=(blk(primary.directory). RLSE.MXIG.CONTIG.secondary.directory).CONTIG.ROUND)
SPACE=(CYL(primary.directory). RLSE.secondary.MXIG.MXIG.secondary. RLSE.
UNIT=3390. Space equal to four tracks is requested for the dataset.4)
Dataset called file1 is created on a 3390 disk.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.‘TRK’ SUB-PARAMETER
• The TRK subparameter is used to allocate space in terms of no of tracks.
. SPACE=(TRK. EXAMPLE : //JOB1 //STEP1 //DATA1 // // JOB A123.
‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.‘CYL’ SUB-PARAMETER
• The CYL subparameter is used to allocate space in terms of no of cylinders. UNIT=3390.
//JOB1 //STEP1 //DATA1 // // JOB A123.4)
. SPACE=(2400. EXAMPLE : //JOB1 //STEP1 //DATA1 // // JOB A123.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.REQUESTING ‘SPACE’ IN BLOCKS
• Space can also be requested in terms of blocks.1000)
Here the space allocated is 1000 blocks having block size of 2400 bytes. UNIT=3390. Blocksize is independent of the device type.
does not have to be contiguous with the location of primary allocation.
. • Secondary space is the additional space requested if the requested primary space is insufficient. • Up to 15 extends may be allocated on secondary space. • Secondary space.PRIMARY AND SECONDARY ‘SPACE’ ALLOCATION
• Primary space is the no of bytes that you expect the dataset will require for storage. when allocated.
. SPACE=(TRK.EXAMPLE :
//JOB1 //STEP1 //DATA1 // // JOB A123. and 25 as secondary space for FILE1.(50.25))
50 tracks are assigned as primary space. UNIT=3390.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.
• This storage space is used to record the names and locations of the members created within the PDS.
. • This subparameter follows the primary and secondary space subparameters.‘DIRECTORY’ SUB-PARAMETER
• The DIRECTORY subparameter is used when defining PDS.
200 tracks are assigned as primary space.(200. UNIT=3390. and 50 as secondary space and 10 tracks are requested for storing name and location information for members that will reside in the PDS
//JOB1 //STEP1 //DATA1 // // JOB A123.50.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.
• A dataset is considered to be closed after the successful completion of a write operation.
. • The release parameter helps free up resources for other jobs.‘RLSE’ SUB-PARAMETER
• The RLSE sub parameter is used to request that space originally allocated to an output dataset be released when the dataset is closed.
.50).‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.EXAMPLE :
//JOB1 //STEP1 //DATA1 // // JOB A123. UNIT=3390.(200.
Ensure that at the end of the job the unused space is released.CLASSROOM EXERCISE
Write a JCL where job name is JOB1 . program P1 is executed creating a dataset FILE1 on Unit 3380 for which the space is allotted in terms of Tracks with a primary space of 15 tracks and secondary space of 30 tracks.
The extra comma between the primary specification and the CONTG parameter is for the RLSE parameter. UNIT=3390. • This parameter applies only to primary space allocations. EXAMPLE : //JOB1 //STEP1 //DATA1 // // JOB A123. 200.‘CONTG’ SUB-PARAMETER
• The CONTG subparameter is used to specify that only contiguous space should be allocated to the data set.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1. .
• The MXIG subparameter is used to specify that space requested
should be allocated on the largest contiguous area of space available on the volume
//JOB1 //STEP1 //DATA1 // // JOB A123. UNIT=3390..RLSE. SPACE=(TRK. 700.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.MXIG)
700 tracks of primary space is requested on a 3390 disk in an area where 700 or more tracks of contiguous space is available.
• The use of this subparameter results in space being allocated as the entire cylinder instead of just portions of it. starting with the first track of the cylinder.
. Access time is decreased. • The system computes the amount of storage required. till the end of the last track. and allocates that number of cylinders to the request. rounds it off to the nearest cylinder. • The advantage associated with the use of this parameter is that data will reside.
//JOB1 //STEP1 //DATA1 // // JOB A123.
...‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1. UNIT=3390.ROUND)
50 blocks of 500 bytes are requested as storage space and the round subparameter results in space being rounded to the nearest cylinder.50. SPACE=(500.
• The DCB parameter let’s you specify file characteristics that are stored in the file’s Data Control Block. • For existing data sets the information is retrieved from the data set label.
• In addition. • The DCB parameter is coded only for a new data set . you don’t have to code the DCB parameter for a
new data set if your application program supplies the required information.
• The DCB parameter has four sub-parameters DSORG.RECFM=format.BLKSIZE=block size)
. LRECL=length. RECFM. • They are keyword sub-parameters so you can code them in any order you want. LRECL and BLKSIZE. SYNTAX : DCB=(DSORG=xx.
‘DSORG’ SUB-PARAMETER • The DSORG sub-parameter specifies the organization of the data set. DSORG Specifies the data set’s organization.as follows PS Physical sequential PO Partitioned DA Direct IS Indexed sequential DCB=(DSORG=PS) Specifies a sequential data set.
.unblocked Fixed length.as follows F FB V VB U Fixed length.‘RECFM’ SUB-PARAMETER
• The RECFM sub-parameter is used to specify the record format of the dataset being created. RECFM Specifies the format of the file’s records.blocked Variable length.unblocked Variable length.
FILE1 is created on a 3390 disk and the parameter F indicates that the FILE1 will contain fixed length records. UNIT=3390.EXAMPLE 1 : //JOB1 //STEP1 //DATA1 // // JOB A123.
.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.
which is used by the system to specify the actual length of the record that follows. • For Fixed Length Record LRECL is equal to the record length.‘LRECL’ PARAMETER
The LRECL ( Logical Record Length ) is used to specify the length of the record.
• For Variable Length Record LRECL is set to the size of the largest record plus 4 bytes.
. SYNTAX LRECL=number Where number is the length in decimal digits. for fixed or variable length records. in bytes.
UNIT=3390.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=FILE1.LRECL=80)
. DCB=(RECFM=F.EXAMPLE :
//JOB1 //STEP1 //DATA1 // // JOB A123.
. • It must be equal to at least the record length plus four bytes for variable length records. • It must be set to the size of the largest block for undefined length records.‘BLKSIZE’ PARAMETER
This parameter is used to specify the blocksize of dataset in bytes. • It must be specified as a multiple of the record length for fixed length records.
‘JAI’ //STEP1 EXEC PGM=PROGRAM1 //DATA1 DD DSN=FILE1.LRECL=80.BLKSIZE=1600)
. // UNIT=3390.EXAMPLE :
//JOB1 JOB A123. // DCB=(RECFM=FB.
• The BUFNO parameter is used to specify the number of buffers to be allocated to virtual storage for the dataset.LRECL=80. BLKSIZE=1600. UNIT=3390. BUFNO=40) DCB parameter
.‘JAI’ EXEC PGM=PROGRAM1 DSN=FILE1. DCB=(RECFM=FB. SYNTAX BUFNO=number EXAMPLE 1: //JOB1 //STEP1 //DATA1 // // // // JOB DD A123.
the record format is Fixed block. unused space to be released at the end of the job. program P1 is executed to create a dataset FILE1 on unit 3380.CLASSROOM EXERCISE
Write a JCL where job name is JOB1.
.volume serial number 234. Record length is 80 and Block size is 1600. the space allotted as primary is 4 cylinders and secondary is 45 cylinders . code for contiguous space.
SYSIN SYSUDUMP. • Use of symbolic parameters in Procedures • The concept of Generation Data Groups To try and solve the classroom exercises. OUTLIM parameters coded on the DD statement. DEST.OBJECTIVES
To understand • The function of DUMMY and Concatenated data sets • The function of special DD statements like SYSOUT.
. SYSABEND • The use of DLM. HOLD. • Importance and usage of Procedures.
CODING DATA SETS AND I/O ON THE DD STATEMENT
Types of data sets are • Dummy • Concatenated Special DD statements are : • SYSOUT • SYSIN • SYSUDUMP • SYSABEND
Position In JCL : // // Name ddname Operation DD Parameters DUMMY Comments Comments
• If DUMMY or NULLFILE is read.
• The Dummy parameter is coded on the DD statement to test the execution of a program without actually reading or writing to a data set. then the Operating System passes an EOF indicator to the program that is being executed.
‘JAI’ EXEC PGM=TEST1 DD DUMMY is executed and a DUMMY dataset is
The program TEST1 accessed.EXAMPLE 1 :
//JOB1 //STEP1 //DATA1 JOB A123.‘JAI’ EXEC PGM=TEST2 DD DSN=NULLFILE
. EXAMPLE 2 : //JOB1 //STEP1 //DATA1
EXAMPLE 1 :
//JOB1 //STEP1 //DATA1 // // JOB EXEC DD DD DD A123. FILE3 are concatenated.CONCATENATING DATASETS
• A dataset can be concatenated and perceived as one file by the operating system by coding each applicable dataset name one after the other.
FILE1 .‘JAI’ PGM=CONCAT1 DSN=FILE1 DSN=FILE2 DSN=FILE3.
. • Used to obtain a dump of the contents of various registers and variables in case of abnormal termination of the job. SPACE=(CYL.
EXAMPLE 1 :
//JOB1 JOB //STEP1 //SYSUDUMP // // A123.(1.‘JAI’ EXEC PGM=PROGRAM1 DD DSN=DUMPFILE.‘SYSUDUMP’ DD STATEMENT
• Sysudump is coded in the name field of the DD statement. UNIT=3390.
• Used to obtain a dump of the contents of various registers and variables in case of abnormal termination of the job ( on an output device ). • SYSTEM AREA.
.‘SYSABEND’ DD STATEMENT
• SYSABEND is coded in the name field of the DD statement.
EXAMPLE 1 :
//JOB1 JOB //STEP1 //SYSABEND DD A123. at the time of abnormal termination will also be written to the output dataset.‘JAI’ EXEC PGM=PROGRAM1 SYSOUT=A.
POSITION IN A JCL : // // Name SYSIN Operation DD Parameters Comments
* or DATA Comments < data follows > /* The * or DATA indicates to the Operating System that input should be accepted from the keyboard or coded in the JCL.‘SYSIN’ DD STATEMENT
• SYSIN is conventional DD name assigned to input data streams which is the data entered when the job is submitted. • The ‘*’ or ‘DATA’ parameter can not be coded in procedures. • /* indicates the end of input data stream in the JCL.
EXAMPLE 2 :
//JOB1 JOB A123............> /* In the second e.‘JAI’ //STEP1 EXEC PGM=PROGRAM1 //SYSIN DD * <...............
....g...‘JAI’ //STEP1 EXEC PGM=PROGRAM1 //SYSIN DD DATA <..EXAMPLE 1 :
//JOB1 JOB A123.. lines of data................ the use of DATA allows us to use special characters // and /* in the data segment. lines of data.....
DLM=@@ <....> /* @@ Here the delimiter is‘@@’ and not ‘/*’ which is also a part of the input data stream......’JAI’ //STEP1 EXEC PGM=PROGRAM1 //SYSIN DD DATA..... EXAMPLE : //JOB1 JOB A123.............. lines of data............
• The DLM parameter specifies the delimiting character that is to be used to mark the end of the input data stream.
POSITION IN JCL
. which may or may not be a remote location.‘DEST’ PARAMETER
• The DEST parameter is used to route output to a specific
. In a JES2 environment the syntax is: DEST=RMTxxxx Or DEST=RMxxxx Or DEST=Rxxxx Or DEST=Uhhh Or DEST=Nxxxx Or
Contd....SYNTAX The syntax depends on the Job Entry Subsystem being used..
RM and R stand for Remote Terminal. and R specifies a remote workstation connected to the node.) DEST=NnnnRyy Or DEST=LOCAL RMT.SYNTAX ( Contd. U specifies a local terminal.
.. N specifies a node. For the syntax : DEST=NnnnRyyy N specifies node.
Here the output is directed to output device assigned to class A and its location is designated by the code RMT1190.‘JAI’ EXEC PGM=XYZ DD DSN=FILE1.EXAMPLE 1 :
//JOB1 //STEP1 //DATA1 // // JOB A123. SYSOUT=A.
.‘JAI’ EXEC PGM=XYZ DD DSN=FILE1. DEST=LOCAL
Output is routed to the local device.EXAMPLE 2 :
//JOB1 //STEP1 //DATA1 // // JOB A123. SYSOUT=A.
• Hold parameter is used to specify whether the output is to be printed immediately or held until further notice. POSITION IN JCL // Name Operation Parameters Comments
//JOB1 //STEP1 //DATA1 // // JOB A123,‘JAI’ EXEC PGM=ABCD DD DSN=FILE1, SYSOUT=A, HOLD=YES.
• The OUTLIM parameter is used to limit the number of lines that are output to the destination specified in the SYSOUT.
POSITION IN JCL
EXAMPLE 1 : //JOB1 //STEP1 //DATA1 // // JOB A123,‘JAI’ EXEC PGM=OUT1 DD DSN=FILE1, SYSOUT=A, OUTLIM=1000.
Output routed to the printer is limited to 1000 lines.
• A JCL procedure is a pre-written segment of code that can be included in a job stream. • The use of procedures helps minimize duplication of code and probability of error. • JCL procedures can be either : Cataloged procedures or In-stream procedures
• Statements of an in-stream procedure appear in the job that invokes the procedure and are not members of any PDS. • In-stream procedures are used mostly for testing procedures that will eventually be cataloged.
. • An in-stream procedure is available only to the job that contains it. • Same instream procedure can be invoked more than once from within a job.
// DISP=SHR //STEP2 EXEC PGM=OUT2 //DATA2 DD DSN=FILE2.EXAMPLE :
Creating and Executing an Instream Procedure //JOB1 JOB A123.‘JAI’ //INPROC1 PROC //STEP1 EXEC PGM=OUT1 //DATA1 DD DSN=FILE1. // DISP=SHR PEND // //STEP77 EXEC PROC=INPROC1 //
• SYS1. It contains mostly system oriented procedures.
• Statements of a cataloged procedure are written and stored in a
partitioned data set.which you can use instead of SYS1.PROCLIB is the system procedure library. • A cataloged procedure can be invoked by any job in the system. • You can also establish alternate procedure libraries.
DISP=SHR EXEC PGM=OUT2 DD DSN=FILE2.EXAMPLE 1 : //CATPRO //STEP1 //DATA1 // //STEP2 //DATA2 // PROC EXEC PGM=OUT1 DD DSN=FILE1. DISP=SHR
A cataloged procedure should never contain a PEND statement
DISP=SHR DD DSN=USER.PROCLIB. DISP=SHR EXEC CATPRO
The PROCLIB DD statement defines the location of the cataloged procedure.
.TEST.JOBLIB.‘JAI’ DSN=USER.Execution Of The Procedure : //JOB1 //PROCLIB // //JOBLIB // //STEP10 JOB DD A123. The EXEC executes the cataloged procedure.TEST.
//name //procstep.ddname Exec DD procedure-name modified-parameter
.OVERRIDING PARAMETERS IN PROCEDURES
• Used to override the parameters of a Procedure for the duration of a job. without actually changing the contents of the original procedure.
.EXAMPLE //PROC1 //STEP1 //DD1 // STEP2 //DD2 PROC EXEC DD EXEC DD PGM=PROGRAM1 DSN=FILE1.DISP=SHR
To execute this procedure with a modification in the disposition of FILE1 from SHR to OLD.DD2 JOB DD A123.DISP=OLD DD DSN=NEWFILE.‘VENU’ DSN=USER. and the data set name FILE2 to NEWFILE.LIB1 DISP=SHR EXEC PROC1 DD DSN=FILE1.TEST.DD1 // STEP2. It is done as:
//JOB1 //PROCLIB // //EXEC1 //STEP1.DISP=SHR PGM=PROGRAM2 DSN=FILE2.
g. DISP=&STAT or SYSOUT=&DEVICE
. you code an ampersand(&) followed by a name.SYMBOLIC PARAMETERS
• Symbolic parameters are used to create procedures for generalized use . For e.
• Symbolic parameters provide a convenient means of assigning
different values to parameters in commonly used JCL procedures. • To code a symbolic parameter in a procedure.
COB(&FILE1).DEVICE=A Here the &DEVICE symbolic parameter is given a value of A. For e.you invoke the procedure as //STEP20 EXEC NEWPRO. // DISP=SHR To supply a value to the &FILE1 symbolic parameter. //STEP10 EXEC CATPRO.SPECIFYING SYMBOLIC PARAMETER VALUES
To supply values to symbolic parameters. EXAMPLE : //NEWPRO PROC //STEP1 EXEC PGM=CALC //DATA1 DD DSN=TRNG.g.NTP. you code them on the EXEC statement that invokes the procedure.FILE1=ASH7
you define it on the procedure’s PROC statement.
. DISP=&STAT If the programmer doesn't code STAT on the EXEC statement that invokes this procedure.COB(DATFILE).
//NEWPRO PROC STAT=SHR //STEP1 EXEC PGM=UVW //DATA1 DD DSN=TRNG.ASSIGNING DEFAULT VALUES TO SYMBOLIC PARAMETERS
To assign a default value to a symbolic parameter .NTP. the default STAT=SHR will be used .
10)). // DISP=&STAT. // DEVICE=CYL..(5.FORMAT=FB //STEP10 EXEC PGM=CALC //DATA1 DD DSN=&FILE1.EXAMPLE :
Suppose you have a procedure as follows : //NEWPRO PROC FILE1=NEWFILE.STAT=SHR.UNIT=3380.. // DCB=(RECFM=&FORMAT)
. // SPACE=(&DEVICE.
If you invoke the previous procedure as //STEP1 EXEC NEWPRO The parameters on the DATA1 DD statement will take the following default values : //DATA1 DD DSN=NEWFILE1. // DISP=SHR.10)).
..UNIT=3380. // SPACE=(CYL(5. // DCB=(RECFM=FB)
// SPACE=(CYL.(5.then you invoke the procedure as : //STEP1 EXEC NEWPRO.STAT=OLD The parameters on the DATA1 DD statement will take the following values : //DATA1 DD DSN=MYFILE. // DISP=OLD. // DCB=(RECFM=FB)
.Similarly in the previous procedure.FILE1=MYFILE.if you want to supply different values to the DSN and DISP parameters and want the other parameters to take the default values.UNIT=3390.10)).
and the new one as a new generation. At a later stage this existing data is updated with new data .
.. The original file is considered as the older generation. They consist of new input which is stored inside a file. • Data processing applications are cyclical in nature.
Contd..THE CONCEPT OF GENERATION DATA GROUPS (GDGs)
• Generation Data Groups are a group of data sets which are related to each other chronologically and functionally. to produce a new file.
Once this limit is reached. This specifies the total number of generations that can exist at one time.THE CONCEPT OF GENERATION DATA GROUPS (Contd.)
• Generations can continue until a specified limit is reached. the oldest generation is deleted.
To understand • • The necessity of Utilities Usage of following IBM Utilities IEBGENER IEHPROGM IEFBR14 MERGE IEBCOPY IEBCOMPR SORT
• A utility is a useful tool that helps in expediting a task. • MVS provides a number of prewritten utility programs that can be used by the analysts, system programmers and application programmers to assist them in organizing data. • A UTILITY program performs a basic function, i.e., it does a routine job which is required repeatedly in an installation.
CLASSES OF IBM UTILITIES
SYSTEM UTILITY PROGRAMS
• System Utility Programs can be used to maintain and manipulate system and user data sets. • These programs must reside in an authorized library. • They can be executed as jobs or be invoked as subroutines of an authorized program.
CLASSES OF IBM UTILITIES
DATA SET UTILITY PROGRAMS:
• Data set utility programs can be used to reorganize, change or compare data at the data set or record level.
• Can be executed as jobs or be invoked as subroutines of a calling program.
CLASSES OF IBM UTILITIES
INDEPENDENT UTILITY PROGRAMS :
• Independent utility programs can be used to prepare devices for system use when the operating system is not available.
FREQUENTLY REQUIRED FUNCTIONS
• Copy sequential files. • Copy partitioned data sets. • Catalog data sets. • Un catalog data sets. • Rename data sets. • Compress partitioned data sets. • Include members to partitioned data sets when a Copy transaction is implemented. • Exclude members to partitioned data sets when A copy transaction is implemented. • Compare sequential and partitioned data sets.
without having to execute a program.• •
Generate generation data groups
Create /delete data sets allocate / de allocate space on data sets or code other functions on the DD statement.
which are required to execute the utility program. //jobname JOB (accounting-information.) programmer-name //stepname EXEC PGM=utility-name.data statements specific to utility follow --.device-class // inputfile DD input-file-features // outputfile DD output-file-features // workfile DD work-file-features // inputdata DD * < --. PARM=value //printname DD SYSOUT=print.> /* //
. follow a general pattern.JCL REQUIRED TO EXECUTE THE UTILITIES
The JCL statements.
SOME IMPORTANT UTILITIES
• IEBGENER • IEBCOPY • IEHPROGM • IEBCOMPR • IEFBR14 • DFSORT • MERGE
• The original data set and the destination names must be specified.IEBGENER
• Most commonly used utility program. • Used to copy one sequential file to another. • Attributes of both the data sets such as RECFM. LRECL must be the same.
device-class DD DSN=source-file-features DD DSN=destination-file-features DD DUMMY JOB
. keyword parameters EXEC PGM=IEBGENER DD SYSOUT=print.programmer-name.CORRESPONDING JCL
//jobname // //stepname //SYSPRINT //SYSUT1 //SYSUT2 //SYSIN // accounting-info.
which is known as LOADING. or a sequential data set ( on a Tape Drive) . • Exclude members of a PDS within a copy transaction
. • Compress Partitioned Data Sets • Include members of a PDS within a copy transaction. which is known as UNLOADING.IEBCOPY
Copy Partitioned Data Sets
• A PDS can be copied to another PDS. • Used to restore PDS to direct access devices from a Tape Drive.
OUTDD=SYSUT2 /* //
. // keyword parameters //stepname EXEC PGM=IEBCOPY //SYSPRINT DD SYSOUT=print.device-class //SYSUT1 DD DSN=source-file-features //SYSUT2 DD DSN=destination-file-features //SYSIN DD * COPY INDD=SYSUT1.CORRESPONDING JCL
//jobname JOB accounting-info.programmer-name.
the SYSUT2 statement is not required and the following have to be coded : //SYSIN DD * COPY INDD=SYSUT1. OUTDD=SYSUT2 /* //
For compressing a data set.•
For loading and unloading the following have to be coded : //SYSIN DD * COPY INDD=SYSUT1. OUTDD=SYSUT1 /* //
To include the members to a PDS the input (SYSUT1) and output (SYSUT2) data set names will be the same and the following have to be coded : //SYSIN DD * COPY INDD=SYSUT1. OUTDD=SYSUT2 SELECT MEMBER = ( mem1.) /* //
• Un catalog a Data Set.IEHPROGM
• Catalog a Data Set.
. • Rename Data Sets. • Create an index of a GDG • Delete the index of an existing GDG.
programmer-name. // VOL=SER=vol-no //SYSIN DD * <.parameters for above functions -> /* //
. // VOL=SER=vol-no // SYSUT2 DD UNIT=unitname. // key-word parameters //stepname EXEC PGM=IEHPROGM //SYSPRINT DD SYSOUT=print-device-class //SYSUT1 DD UNIT=unitname.CORRESPONDING JCL //jobname JOB accounting-information.
CATALOGING A DATA SET
A data set can be cataloged using the CATLG statement. //SYSIN DD * CATLG DSN=data-set-name VOL=device-name=vol.
CATLG DSN=data-set-name VOL=device-name=volume-number.no /* //
. The above is coded in the SYSIN DD statement.
. //SYSIN DD * UNCATLG DSN=data-set-name /* // SYSUT2 is not coded.UNCATALOGING A DATA SET
A data set can be uncataloged using the UNCATLG statement.
//SYSIN DD * RENAME DSN=data-set-name. VOL=device-name=volume=number NEWNAME=new-name /* //
.RENAMING THE DATA SET
A data set can be renamed using the RENAME command.
• • • •
Used to Compare two sequential data sets. The data sets that are compared must have same record length and format. however block size need not be the same.
If the two data sets are identical then zero will be returned upon successful completion of the job. If the data sets are not identical then a condition code of 8 will be returned.
• Compare two partitioned data sets.
features //SYSIN DD * COMPARE TYPORG=data-set-type /* //
//jobname JOB accounting-inform... // keyword-parameters //stepname EXEC PGM=IEBCOMPR //SYSPRINT DD SYSOUT=print-device-class //SYSUT1 DD DSN=data-set-1-features //SYSUT2 DD DSN=data-set-2..programmer-name.
without having to execute any explicit program. It executes a single statement which specifies the end of the program. This program is used to code functions that are commonly available on the DD statement. Since this program does nothing it can be used to check the syntax of JCL code without affecting any data sets.IEFBR14
T his program is a Null Program. deletion and updation of data sets. such as the creation.
.‘ASHRAF’ //STEP1 //DD1 // EXEC PGM=IEFBR14 DD DSN=COBOL.EXAMPLE 1:
//UNCATLOG JOB A123.FILE1. DISP=(OLD.UNCATLG)
IEFBR14 Program is used to uncatalog the data set called COBOL.FILE1.
EXEC PGM=IEFBR14 DD DSN=COBOL.DELETE)
IEFBR14 Program is used to DELETE the data set called COBOL.FILE1.EXAMPLE 2:
//DELETE1 JOB //STEP1 //DD1 //
Used to sort records in ascending or descending order within a file
Merge two or more sorted files into a single file.
.. this statement may be omitted. //SYSPRINT DD //* Defines the message data set //SORTIN DD //* Defines the INPUT data set (contd.. If it is in a //* system library.)
.. programmer-name.CORRESPONDING JCL
//JOB1 JOB Accounting-inform. // Keyword-parameters //STEPNAME EXEC PGM=DFSORT //STEPLIB DD //* Defines the library containing the SORT program..
//SORTWKNN DD //* Defines a WORK storage data set //* In most cases one data set is sufficient. //SORTOUT DD
//* Defines the OUTPUT data set //SYSIN DD *
//* contains SORT program control statements.
‘JAI’ //STEP1 EXEC PGM=DFSORT //SYSOUT DD SYSOUT=A //SORTIN DD DSN=PROJECT1.RLSE) //SORTOUT DD DSN=PROJECT1.DELETE).(2. DISP=SHR //SORTWK01 DD UNIT=SYSDA.1).JCL. // DISP=(NEW.CATLG.RLSE) // DCB=(RECFM=FB. // LRECL=80.EXAMPLE 1 :
//JOB1 JOB (A123). // SPACE=(CYL.CH) /* //
.BLKSIZE=800) //SYSIN DD * SORT FIELDS=(2.D.(2.6.1).JCL. // UNIT=UNIT1. // SPACE=(CYL.
‘JAI’ //STEP1 EXEC PGM=SORT //SYSOUT DD SYSOUT=A //SORTIN1 DD DSN=PROJECT. DISP=SHR //SORTIN2 DD DSN=PROJECT. DISP=SHR //SORTIN3 DD DSN=PROJECT.MRGFILE.SPACE=(CYL.6.DATA3.DELETE).1).(2.A. // DISP=(NEW.LRECL=80) //SYSIN DD * MERGE FIELDS=(2.EXAMPLE 2 :
//JOB1 JOB (A123).CATLG.DATA1.CH) /* //
. DISP=SHR //OUTFILE DD DSN=PROJECT1.DATA2. // UNIT=UNIT1.RLSE) // DCB=(RECFM=FB.