Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
need details on return code
Goto page 1, 2  Next
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL
Author Message
veena_nagesh2002
Warnings : 1

Active User


Joined: 07 May 2005
Posts: 60
Location: hyderabad

PostPosted: Wed May 14, 2008 3:07 pm    Post subject: need details on return code
Reply with quote

I have job with two steps and both steps are submitting two different jobs

Is it possible to execute the step2 based on completion of job (RC) which is submitted in the prior step. if so can some body provide me the details
Back to top
View user's profile Send private message
References
PostPosted: Wed May 14, 2008 3:07 pm    Post subject: Re: need details on return code Reply with quote

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 2321
Location: italy

PostPosted: Wed May 14, 2008 3:11 pm    Post subject: Reply to: need details on return code
Reply with quote

NO!

cross jobs step-condition-code checking is possible ( to some extent ) only thru a scheduler
Back to top
View user's profile Send private message
veena_nagesh2002
Warnings : 1

Active User


Joined: 07 May 2005
Posts: 60
Location: hyderabad

PostPosted: Wed May 14, 2008 3:15 pm    Post subject:
Reply with quote

thanks for quick reply

so there is no solution apart from scheduler
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 1088
Location: At my desk

PostPosted: Wed May 14, 2008 6:12 pm    Post subject: Re: Reply to: need details on return code
Reply with quote

enrico-sorichetti wrote:
NO!

cross jobs step-condition-code checking is possible ( to some extent ) only thru a scheduler
But if the job with the RC in question is submitting the second job, can the RC be passed as a SET type parameter?
Back to top
View user's profile Send private message
gcicchet

Active User


Joined: 28 Jul 2006
Posts: 295

PostPosted: Thu May 15, 2008 4:32 am    Post subject:
Reply with quote

Hi,
why have a job submit another 2 jobs ? Why not submit the real job and if rc of 0 then submit the next job.


Gerry
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 1088
Location: At my desk

PostPosted: Thu May 15, 2008 4:50 am    Post subject:
Reply with quote

gcicchet wrote:
why have a job submit another 2 jobs ? Why not submit the real job and if rc of 0 then submit the next job.
That sounds like "there is no solution apart from scheduler".......
Back to top
View user's profile Send private message
gcicchet

Active User


Joined: 28 Jul 2006
Posts: 295

PostPosted: Thu May 15, 2008 5:03 am    Post subject:
Reply with quote

Hi,
even a scheduling tool would not fix this problem, how would you prevent step2 from executing ?


Gerry
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 1088
Location: At my desk

PostPosted: Thu May 15, 2008 5:26 am    Post subject:
Reply with quote

gcicchet wrote:
even a scheduling tool would not fix this problem, how would you prevent step2 from executing?
No imagination?
Think about what the OP is trying to do, imagine a solution....
It's fun to play with problems as they 'stage' in your mind.....grin.....
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 2439
Location: Brussels once more ...

PostPosted: Thu May 15, 2008 11:28 am    Post subject:
Reply with quote

Make it all one biggggggggggggggg jobby and use conditional execution
Back to top
View user's profile Send private message
tchen40

New User


Joined: 12 Sep 2007
Posts: 27
Location: Los Angeles, Ca

PostPosted: Thu May 15, 2008 10:32 pm    Post subject:
Reply with quote

What we have currently is -

Job A will submit jobs B and C. We want job C to run based on conditions from B.

My solution is have job A submit job B... The submission of job C is a step in job B and that step that'll submit the job has the COND parm in it coded for whatever condition it is that you'll want job C to run.
Back to top
View user's profile Send private message
dick scherrer

Global Moderator


Joined: 23 Nov 2006
Posts: 6756
Location: 221 B Baker St

PostPosted: Thu May 15, 2008 11:31 pm    Post subject:
Reply with quote

Hello,

What is the reason for these jobs submitting each other?

Sounds like a single job with proper conditon code testing would work just fine icon_confused.gif
Back to top
View user's profile Send private message
tchen40

New User


Joined: 12 Sep 2007
Posts: 27
Location: Los Angeles, Ca

PostPosted: Thu May 15, 2008 11:43 pm    Post subject:
Reply with quote

well, as I understand it... Job A curently submits B and C... veena_nagesh2002 wants job C submitted conditional of the RC of job B. How can job A know what the return code of job B is ? Not to mention we don;t even know how ling it would take job B to finish.
Back to top
View user's profile Send private message
dick scherrer

Global Moderator


Joined: 23 Nov 2006
Posts: 6756
Location: 221 B Baker St

PostPosted: Thu May 15, 2008 11:48 pm    Post subject:
Reply with quote

Hello,

Quote:
How can job A know what the return code of job B is ? Not to mention we don;t even know how ling it would take job B to finish.
If this was implemented as a single job with condition code testing, it would not matter. Step(s)A would run, then step(s)B, then step(s)C as determined by the COND= testing all within the same job.

Just because something runs "some way", does not mean it has to run that way forever. If the requirement has changed or is now better understood, it may make good sense to modify the process.
Back to top
View user's profile Send private message
tchen40

New User


Joined: 12 Sep 2007
Posts: 27
Location: Los Angeles, Ca

PostPosted: Fri May 16, 2008 12:07 am    Post subject: Re: need details on return code
Reply with quote

veena_nagesh2002 wrote:
Is it possible to execute the step2 based on completion of job (RC) which is submitted in the prior step. if so can some body provide me the details


I don't believe you understand what's required here. Veena doesn't care about the step that submits the job. It's always going to be 0. Then step 3 which submits job C will always run.

He wants to have job C submitted based on the return codes that job B gets. not what the step that submitted job B gets (which will always be 0). And I'll bet without even knowing what it is that job B does, step 3 would've already submitted job C before job B is even done.
Back to top
View user's profile Send private message
dick scherrer

Global Moderator


Joined: 23 Nov 2006
Posts: 6756
Location: 221 B Baker St

PostPosted: Fri May 16, 2008 12:15 am    Post subject:
Reply with quote

Hello,

Quote:
I don't believe you understand what's required here.
Sorry, but i believe i completely understand what is needed - at least from a business perspective.

What i do not understand is the stubbornness (not Veena's - no response for a while from Veena, but yours) to maintain/implement the 3 job architecture. I see no real reason to try to dance around the current issue. If all is done in one job, all of the "scheduling" issues go away.

Maybe Veena will explain why there is a need to run 3 separate jobs. . . If not, it is all just speculaton.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL All times are GMT + 6 HoursGoto page 1, 2  Next
Page 1 of 2