View previous topic :: View next topic
|
Author |
Message |
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
FWIW, here's an undocumented method to execute or not execute steps in a JOB. I use this in many disaster recovery JOB's, which have many steps which I may want to execute or not execute.
Using 1's and 0's is akin to boolean logic (1=ON, 0=OFF).
Code: |
// SET RUNSTP1=1
// SET RUNSTP2=0
//*
// IF &RUNSTP1=1 THEN
//* THE STEP WILL RUN, VARIABLE RUNSTP1 RESOLVES TO A 1
// ENDIF
//*
// IF &RUNSTP2=1 THEN
//* THE STEP WILL NOT RUN, VARIABLE RUNSTP2 RESOLVES TO A 0
// ENDIF
//*
//
|
Bill |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
The fact that I cannot do this the way that I should be able to do it is very clear to me now. |
Why do you believe you "should be able"
If you should be able, IBM would have implemented same.
It is quite important to test an approach before commiting to it and then needing to back-up and re-group. |
|
Back to top |
|
|
Alex Garcia
New User
Joined: 06 Jan 2011 Posts: 9 Location: Kansas City
|
|
|
|
dick scherrer wrote: |
Hello,
If you should be able, IBM would have implemented same.
|
So if IBM hasn't implemented it, then it shouldn't be done? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Not until you (or a large group) convince IBM to change "the way it works"
Actually, "should" has little to do with it - as of the current implementation, you cannot do what you want the way you want to do it. . .
Many (most?) of us have been frustrated by the way some things are. Usually, they are not going to change (especially not quickly enough to be used for anything currently being worked on). |
|
Back to top |
|
|
parsesource
New User
Joined: 06 Feb 2006 Posts: 97
|
|
|
|
Robert Sample wrote: |
Unless you explicitly name each step of the proc by using the appropriate two-level identifier, what you want to to cannot be done. You might want to investigate using your site's job scheduler to schedule three separate jobs, in which case the only condition codes to matter will be the ones in the current job. |
it can be done the following way. you have to add the stepname as parameter to the proc.
Code: |
//A JOB
//STEP1 EXEC FOO,STEPNAME=STEP1
//STEP2 EXEC FOO,STEPNAME=STEP2
//STEP3 EXEC FOO,STEPNAME=STEP3
//
|
and FOO looks like
Code: |
//FOO PROC
//PRCSTEP1 EXEC PGM=BAR
// IF (&STEPNAME.PRCSTEP1.RC=0) THEN
//PRCSTEP2 EXEC PGM=SUMMAT
// ENDIF
|
|
|
Back to top |
|
|
|