How can we pass data from cobol to JCl?
Answers were Sorted based on User's Feedback
Answer / sri
When someone ask you that question first thing you need to
do is you post a question to him.
Passing data from COBOL to JCL means where in JCL ?
Do you mean a file? File is also a part of JCL. If it is
file then your answer is WRITE the data into the file.
Do you mean a PDS member ? Then WRITE the data or what ever
into the PDS member.
Do you mean SYSOUT ? If so just DISPLAY the value.
If he says not these three then he need to tell what is the
purpose of moving data to JCL ? for you to give an answer.
| Is This Answer Correct ? | 42 Yes | 2 No |
Answer / guest
We can pass the data from cobol to JCl
ex: Move 4 t0o return code.
| Is This Answer Correct ? | 31 Yes | 4 No |
Answer / anil prajapati
we can pass data from cobol to jcl by using return-code
like
move 450 to return-code
if we are passing data likeit then at run time the maxx
return code will be this code if move code is a negative
number then after subtracting from 4096 maximum return code
will be displayed
| Is This Answer Correct ? | 19 Yes | 2 No |
Answer / rosi
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 ? | 6 Yes | 4 No |
Answer / mr2981
by using file we can pass data ,by using return code
| Is This Answer Correct ? | 9 Yes | 14 No |
Answer / gigish thomas
create a Symbolic Parameter in jcl woith out goiving any
value.In the job step passthis symbolic parameter through
PARM parameter to cobol program.in the linkage section of
the cobol program assign the value/string to the symbolic
variable. It will automatically reflect to the symbolic
variable which was defined in JCL program.
| Is This Answer Correct ? | 4 Yes | 18 No |
Answer / vip
By using the parm parameter in jcl and defining the
datanames in the linkage section of the cobol program.
| Is This Answer Correct ? | 9 Yes | 30 No |
write a program to eliminate duplicate records in a input file and send them to output file.
In a program, there are 2 sections defined say SECTION-A and SECTION-B. There is a paragraph say CALC-INT in both the sections. If this para has to be called directly for SECTION-A, then PERFORM CALC-INT will not work as it is present in both sections. How the PERFORM statement has to be coded here?
What is the utilization of copybook in cobol? Could we utilize a similar copybook?
plz any one tell clearly the justify right clause?
How to execute a set of JCL statements from a COBOL program?
how do u list the abended jobs?
WORKING-STORAGE SECTION. 01 VAR1 COMP-2 VALUE 0. PROCEDURE DIVISION. MOVE 10.2115 TO VAR1. DISPLAY 'VAR1 =' VAR1. GOBACK. 10.2115 is stored as .10211499999999996E 02 in OS VS Cobol 10.2115 is stored as .10211500000000000E 02 in ecobol. Any reason why?
where did you see the information regarding abend codes in jcl?
what is mainframe? what is the mainframe software ? what is use in s/w field?
Whats the use of Examine command? can someone help me?
if we have a 10 steps how to override the 4th step in jcl?
What are the divisions in a cobol program? Which one is the mandatory division among them?