I have 80 odd jobs (JCLs) which I run quite often, its a clone of a batch which runs on CA7, output files have my racf ID as 2nd qual. I do not have previlieage to set up a schedule in CA7.
Is there a way I can submit all these jobs in one go to run one after another? They are named in such a way list (sorted on name) reflects dependency.
I want to add condition codes say step STEP0002 should execute only if RC from STEP0001=0 and step STEP0003 should execute of RC from step STEP0002 is LE to 8?
I tried above code but it seems my condition codes are being ignored.
1. If there is a dependency between the jobs, then usually we add Internal reader step as the last step in the jcl, along with condition code check(if required).
Kindly check in your case.
2.
Post the JESMSG contents.
COND on exec:
If it evaluates to true, particular step is BYPASSED.
May be you need to change
//STEP0003 EXEC TSTBPROC,MEM=PSD3,COND=(8,LT)
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
If you submit multiple jobs at one time like you posted, JES will NOT guarantee that they will execute in the order submitted -- so the results you report are normal and expected.
You need to change EACH JOB so the last step of the job submits the next job. The ONLY other viable option is to use a job scheduler to submit them in the desired sequence. Submitting multiple jobs at one time, as you have discovered, does not produce the results you want.
Also, I think you misunderstand -- the IEBGENER will give you a return code of 0000 as long as the job was submitted. IEBGENER does not have any way of determining whether or not the submitted job had a return code of 0000 or not -- nor does it matter; the submitted job runs in a separate address space and hence there is no interaction between the submitted job and the IEBGENER.