Can we submit a job from cobol Program, if yes, how ?

JES2/3, JCL, utilities.
Post Reply
Kanika
Registered Member
Posts: 21
Joined: Sat Jul 13, 2013 6:31 pm

Can we submit a job from cobol Program, if yes, how ?

Post by Kanika »

Hello,

Can we submit a job from cobol Program, if yes, how ? Please help.
zprogrammer
Global Moderator
Global Moderator
Posts: 588
Joined: Wed Nov 20, 2013 11:53 am
Location: Mars

Re: Can we submit a job from cobol Program, if yes, how ?

Post by zprogrammer »

zprogrammer
User avatar
Robert Sample
Global Moderator
Global Moderator
Posts: 1895
Joined: Fri Jun 28, 2013 1:22 am
Location: Dubuque Iowa
United States of America

Re: Can we submit a job from cobol Program, if yes, how ?

Post by Robert Sample »

Yes, as Pandora-Box alluded, you can open an output file in COBOL that points to the internal reader, write lines of JCL to that file, and submit jobs to the system. Note, however, that there are some things to be aware of -- such as ending a job if you are running in CICS, inheritance (or not) of user id information, and having job statement errors will cause the job to flush without ever starting.
dick scherrer
Former Team Member
Posts: 62
Joined: Wed Aug 07, 2013 6:43 pm

Re: Can we submit a job from cobol Program, if yes, how ?

Post by dick scherrer »

Once you have tested your program and have it working as you want (generating the desired JOB stream), you need to talk with someone on your system and ask for the rules for using the Internam Reader. This varies from site to site.
Hope this helps,
d
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “JCL - Job Control Language.”