View previous topic :: View next topic
|
Author |
Message |
raghu_4412 Warnings : 1 New User
Joined: 01 Mar 2004 Posts: 4 Location: Bangalore
|
|
|
|
hello sir,
How many JOBS we can submit in a Single JCL? |
|
Back to top |
|
|
bluebird
Active User
Joined: 03 Feb 2004 Posts: 127
|
|
|
|
this question raised a debate here...
it seems there are no limit
depending on how u submit your job step with Iebgener and internal reader, or pure JES statements.
(JCL is limited in the number of steps per deck - I think 255)
look fore older posts in the same topic |
|
Back to top |
|
|
khamarutheen
Active Member
Joined: 23 Aug 2005 Posts: 677 Location: NJ
|
|
|
|
Hi raghu_4412,
I think there is no limit. bcz as per the step limit only v have. a job may trigger another and more jobs.. no limit. |
|
Back to top |
|
|
priyesh.agrawal
Senior Member
Joined: 28 Mar 2005 Posts: 1448 Location: Chicago, IL
|
|
|
|
There is no LIMIT in terms of number of job cards in a JCL.
Other factor may affect but not the number of job cards.
Regards,
Priyesh. |
|
Back to top |
|
|
anilbatta
New User
Joined: 13 Nov 2005 Posts: 22
|
|
|
|
Hi
You can submit many number of jobs as you want based on certain conditions using COND parameter we can do this. Suppose you have executed one job Job1, and the return code of Job 1 is 4 and we can write this in a Jcl in such a way that if Job 1 RC is 4 then execute Job 2..etc
This can be possible in JCL and that's the feature of Mainframe.And apart from this, we can execute 255 steps in a single JCL.
Regards
Anilbatta |
|
Back to top |
|
|
priyesh.agrawal
Senior Member
Joined: 28 Mar 2005 Posts: 1448 Location: Chicago, IL
|
|
|
|
Quote: |
You can submit many number of jobs as you want based on certain conditions using COND parameter we can do this. Suppose you have executed one job Job1, and the return code of Job 1 is 4 and we can write this in a Jcl in such a way that if Job 1 RC is 4 then execute Job 2..etc |
Even if it is not done.... Cascading all the job cards one by one in the JCL is sufficient to run them all.
Regards,
Priyesh. |
|
Back to top |
|
|
kumar_ngl Warnings : 1 New User
Joined: 05 Aug 2005 Posts: 50 Location: chennai
|
|
|
|
the limit is 255, even its 255 it will give some problems in terms of resource sharing
kumar.p.v |
|
Back to top |
|
|
Imran
New User
Joined: 26 Dec 2005 Posts: 12 Location: Pune
|
|
|
|
HI Priyesh
If we cascade by giving jobcards for each step then all the steps will execute at a time. I,E iT IS EQUIVALENT TO SUBMITTING THOSA MANY JOBS AT A TIME.
If the steps are not dependednt on each other then we can cascade.
Regards
Imran |
|
Back to top |
|
|
priyesh.agrawal
Senior Member
Joined: 28 Mar 2005 Posts: 1448 Location: Chicago, IL
|
|
|
|
Hi Imran,
By cascading I meant to enlist all the jobs one after one in a JCL.
As anilbatta given above some details on how to run more than one jobs in a single JCL, I was giving another way of running more than one job in a single JCL. Like..
Code: |
//JOB#1
//JOB#2
//
::
::
//JOB#N |
Quote: |
If we cascade by giving jobcards for each step then all the steps will execute at a time. I,E iT IS EQUIVALENT TO SUBMITTING THOSA MANY JOBS AT A TIME. |
Again its not mendatory that all the enlisted job cards will be submitted at the same time, it may vary on various factors.
Regards,
Priyesh. |
|
Back to top |
|
|
Imran
New User
Joined: 26 Dec 2005 Posts: 12 Location: Pune
|
|
|
|
Ya Priyesh
U r absolutely right..its not necessary that all jobs will be submitted at a time . It depends on the initiators and the JES.
Regards
Imran |
|
Back to top |
|
|
Anurag Singh
New User
Joined: 20 Jan 2008 Posts: 25 Location: India
|
|
|
|
Here I wanted to ask about one doubt related to same question,
I want to Run 3 Jobs from a Single Job based on the Return Code Respectively.
( I.e. Job two should Run based on the Return Code of First Job n similarly the JOb 3 based on the RC of Job 2 )
I dont want to copy all 3 jobs content in one Job ,
Please Suggest me the Solution with Code Example. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Have job 1 submit job 2 thru the internal reader when job 1 successfully completes. Have job 2 submit job 3 thru the internal reader when job 2 successfully completes.
The code to do this is simply an IEBGENER step that "writes" the next job/jcl to INTRDR.
If you are not familiar with the internal reader, there are several examples in the forum. |
|
Back to top |
|
|
Anurag Singh
New User
Joined: 20 Jan 2008 Posts: 25 Location: India
|
|
|
|
Could any one plzz show the example , how to use INTRDR with the Return code check? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
You cannot do that with jcl.
I suggest you re-think the implementation of your requirement.
One way would be to have MASTERJB end once JOB1 is submitted. Then either add additonal steps to JOB1 to be run conditionally or have another submit step that would conditionally run when the rc is as you need.
Is there some reason to submit JOB1 rather than just including the JOB1 process(es) in MASTERJB to be run conditionally? |
|
Back to top |
|
|
Anurag Singh
New User
Joined: 20 Jan 2008 Posts: 25 Location: India
|
|
|
|
Hi,
with Context to my previous Post , if we cannot capture the RC of jobs submitted using INTRDR,
then whether we can use REXX program for this ??
My requirement is as like below given,
I have 5 job in a dataset , and i have to run each job based on the Return Code of the Previous job,
How can i fulfill the Requirement ?? |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10873 Location: italy
|
|
|
|
... Use a scheduler
... add a step to each job to submit the next one |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
I have 5 job in a dataset , and i have to run each job based on the Return Code of the Previous job, |
What business reason is there that these be 5 separate jobs
Easier to understand and maintain would be 1 job with 5 steps conditionally executed. . . |
|
Back to top |
|
|
Anurag Singh
New User
Joined: 20 Jan 2008 Posts: 25 Location: India
|
|
|
|
Hi ,
i cannot add any step in the 5 jobs which i have to run,
Just for example i have mentioned 5 jobs, BTW the actual requirement is as like i want to automate the Batch cycle which is having a set of nearly 30 jobs in a dataset each for different scenario.
and almost all are depending on the previous job RC,
so to fulfill this requirement i created a master job , which is submitting the jobs form the dataset using INTRDR,
however here all the jobs are getting submitted in a random order, and i am not able to schedule them as per the required order ,
Now i want to know , is there any way, through which i can schedule the jobs ,
or through the REXX pgm i can capture the RC of the JObs submitted?
Kindly guide me . |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Quote: |
is there any way, through which i can schedule the jobs
Kindly guide me . |
Kindly use Enrico's suggestion and implement your requirement using the system scheduler software on your system.
Your requirement is normal and is one of the main reasons there is scheduling software. |
|
Back to top |
|
|
|