How to execute a set of JCL statements from a COBOL program?
Answers were Sorted based on User's Feedback
Answer / vishal
we can declare a record in file section and can pass the
statementa to that record as shown..
E.D
fole_control.
select jclfile assign to jcldd
file section.
fd jclfile
01 jcl_record pic x(80).
P.D.
mainpara.
open output jcl_record
move "//job job1, notify=&sysuid" to jcl_record.
move "//step1 exec pgm=pgm1" to jcl_record.
.......
.......
close jcl_record.
then route the file to internal reader INTRDR in jcl
as shown..
//step1 exec pgm=pgm1
//dd3 dd dsn.......
//jcldd dd sysout=(*,INTRDR)
(here the job will get submitted automatically FROM COBOL)
| Is This Answer Correct ? | 7 Yes | 2 No |
Answer / anoop
You can execute JCL from cobol programs.
Write the jcl statements into a file and open it in out put
mode.
| Is This Answer Correct ? | 8 Yes | 12 No |
01 a pic s9(5) value -12345, if we disply a , the sign will overpunched with last digit but i need to get the miuns sign in the result?
In A cobol program , we can use COPY Statement in FILE- SECTION / WORKING-STORAGE SECTION / ENVIRONMENT DIVIION basically what is the difference
i have the job which has written updated 100 records into the table and for 101th record it got abended and i want to start the job again and should wirte from 101th record not from 1st record..how to do it..?
What are the different open modes available in cobol?
What are the different forms of EVALUATE statement?
how to fetch the record before the last record in a cobol file( its a huge file and if the key field is not known)
can i use multiple when statements in search & search all ? justify ur answer?
can we print comp 3 stmts how ?
If you are current on the owner of a set, what is the difference between obtain next and obtain first?
diffrence between z(2) and z9(2)
write a cobol logic. i have file that has 10 records .1 record go to first output file and second record goes to 2 output and etc
how do you reference the variable block file formats from cobol programs