JCL Notes
JCL Notes
JCL Notes
M parameters while calling the proc, will the override only apply to the first s
tep in the proc or all the steps for all the above parameters? Answer
# 1
You may exclude. It depends whether you want to override
any parameter for the whole proc or for a specific procstep.
If you want to do it for a particular step then the format
is COND.PROCSTEP = value. If you want to do it for whole
proc then you may use unqualified overriding parameters
like EXEC PROC TIME= , REGION = etc but the parameters are
to be in the same order as they are in the actual proc.
how will be submit 1 jcl by other jcl? means that how 'll submit one job by othe
r job?? Answer
# 2
You can submit thru IEBGENER utility by copying your job in
the internal reader. Please go thru the steps :
A$xxxx JOB (1354),'SAURAV PAUL',CLASS=x,MSGCLASS=x,
NOTIFY=&SYSUID
STEP1
EXEC PGM=IEBGENER
SYSPRINT DD SYSOUT=*
SYSUT1 DD DSNAME=abcDISP=SHR
SYSUT2 DD SYSOUT=(*,INTRDR)
SYSIN
DD DUMMY
How to execute 300
# 6
In a job max no of
we have to submit
by using 'internal
ex..
// step1 exec...
.
.
.
Wrete a JCL to compare two files and mached records move to onc file & un mached
rows wants to another file? Answer
# 2
It can be done using icetool.
//STEP001 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=INPUT.FILE1,
//
DISP=SHR
//
DD DSN=INPUT.FILE2,
//
DISP=SHR
//NODUPES DD DSN=OUTPUT.NODUP,
//
DISP=SHR
//DUPES DD DSN=OUTPUT.DUP,
//
DISP=SHR
//TOOLIN DD *
SELECT FROM(SORTIN) TO(NODUPES)
ON(x,y,CH) NODUPS
SELECT FROM(SORTIN) TO(DUPES)
ON(x,y,CH) ALLDUPS
If job is submitted with typerun = hold then how can we submit the same job? Ans
wer
# 1
Go to SDSF and tyep A against the job entry. That should
release the held job to execute.
I have a JCL which 20 steps. How do I execute 17 th step alone (It should execut
e only 17ths tep.and it should not execute 18,19,20 steps?? Answer
# 5
Hi,
Code as: RESTART=PROCNAME.STEP17,COND=(4095,NE)
This executes 17th step only and no other step. For
successful execotuin, you will recieve message 'STEP17
PROCNAME - ENDED BY CC 0000 - TIME=nn' in JESMSGLG in SPOOL
Ans: There is a better way of doing it as given below:
//STEP001 EXEC PGM=IEBEDIT
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DSN=XXX.GENERAL.STUDY(TEST001),DISP=SHR
//SYSUT2 DD SYSOUT=(A,INTRDR)
//SYSIN
DD *
EDIT TYPE=INCLUDE,STEPNAME=(STEP0017)
/*
Here, I have used the utility, IEBEDIT to execute only the
required step. You can also, given the syntax,
EDIT TYPE=INCLUDE,STEPNAME=(STEP0017,STEP0021,STEP0099) to
execute the reqd steps only.
DD DSN= ,DISP=SHR
DD DSN=
DD SYSOUT=*
control statement is used to convert the
from VB to FB.
There are a set of 10 files and a customer will be selecting random no of files(
i.e they may be more than 2, may not be in the order).Sometimes he might just se
lect one file or sometimes no files at all.How do you code a JCL for this? Is it
possible to code just JCL alone for this problem? Answer
# 1
Hi,
I don't know the exact answer to this query.
But I have following approach.
Suppose I have a cobol pgm (say) PGM123 that is picking up
files randomly. (We definately need 1 application pgm to
process any of those 10 files randomly. This is my basic
assumption)
I will code a PARM or SYSIN DD * where in my customer can
change order of selection of files .
Say if customer enters PARM as ABCD in order then I will
move this PARM ABCD in a working storage variable in COBOL
PGM and will read each byte A (assign to process file-1)
if second byte is B then process file-2 of third byte is C
then process file-3 and so on. If the cutomer changes this
parm as EDA then files processed will be file-5 then file-4
then file-1.
How to execute a set of JCL statements from a COBOL program ?
# 1
Use a file //dd1 DD sysout=(*,intrdr)write your JCL to this
file. Pl some one try this out
Ans: Before doing this alll the JCl statements shud be written to
the file mentioned in DD1 by the cobol pgm
Ans : using internal reader concept u can
Ans :we can do this by SYSOUT=(*,INTRDR),internal reader concept.
Ans: Yes, can be very much done. Only thing is that the dataset
which contains this JCL statements should be mapped to the
JCL dd statement with INTRDR
How do you submit JCL via a Cobol program? Answer
# 2
Below is explanation with example:THE BELOW GIVEN IS AN EXAMPLE OF HOW TO SUBMIT A JCL FROM A
COBOL PGM:
============================================================
============
COBOL CODE WHICH HAS THE JCL STATEMENTS:
=========================================
IDENTIFICATION DIVISION.
PROGRAM-ID. PROG55.
ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
SELECT IN-FILE ASSIGN DDFILE1
ORGANIZATION IS SEQUENTIAL
MSGLEVEL=(1,1),NOTIFY=XXXXX'
TO IN-REC.
WRITE IN-REC.
MOVE '//STEPDEF EXEC PGM=IEFBR14'
WRITE IN-REC.
TO IN-REC.