Passing a variable parm from JCL to a cobol/db2 program
Answer / tejaratbours
hi.
i need help
i need Passing a variable parm from JCL to a cobol/db2
program
I'm trying to write a batch cobol/db2 pgm wich receive in
linkage section some paremeters
I succeeded to pass a static string of characters but what
I need is variable parameters (INPUT )
//DDB5A59 JOB CLASS=A,MSGCLASS=R,MSGLEVEL=(1,1),NOTIFY=xxxx
// REGION=0M
// SET INPUT=MYNAME <=====
//PH01S01 EXEC PGM=IKJEFT01,DYNAMNBR=20,COND=(4,LT)
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
DSN SYSTEM(DBSN)
RUN PROGRAM(COBPROG) PLAN(NACPLN) -
PARMS('INPUT') -
LIB('MYDB.TRNSCTN.LOADLIB')
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//INFILE DD DSN=MYDB(&INPUT),DISP=SHR
//ERRLST DD SYSOUT=P,DCB=RECFM=F,FCB=L56
The program (cobprog) is that when I run the job ,if PARMS
('&INPUT') returns :&INPUT and
if PARMS(&INPUT) returns :null
i need "myname" to the cobol/db2 program and name of the
member (DSN=MYDB(&INPUT),DISP=SHR)
Do you think helpe me?
Thanks
| Is This Answer Correct ? | 3 Yes | 5 No |
I HAVE A VB BLOCK WHICH IS USED AS INPUT IN COBOL CONATINING SOME RECORDS CAN I CHANGE THE FILE FROM VB TO FB?
how to resolve soc-7 ? please tell me
What is dummy parameter in JCL??
How do you skip a particular step in a proc/JOB?
What is Cataloged Procedures?
Suppose I have 5 dataset listed under a single DD name in a catlogued PROC. How can I override one of those 5 dataset (say 3rd dataset)?
what is a MODELDSCB?
When you specify multiple datasets in a JOBLIB or STEPLIB, what factor determines the order?
What is the parameter to be passed in the job card for the unlimited time , irrespective of the job class ?
Suppose I have a program in cobol name ”careerride” and want to execute the program by jcl. Specify the process?
What is the purpose of the dd keylen parameter?
How is a new GDG coded?