View previous topic :: View next topic
|
Author |
Message |
Kmr.deepakcs
New User
Joined: 11 Oct 2013 Posts: 37 Location: India
|
|
|
|
Dear experts,
As all we know that ibm stated that we cannot bypass first step1 in proc or jcl means step1 will execute regardless wht return code.
But when i run this code it bypasses step1 by using cond =only in step1.
Code: |
//SHRDV02T JOB NOTIFY=&SYSUID
//STEP1 EXEC PGM=IEFBR14,COND=ONLY
//DD1 DD DSN=SHRDV02.DEEPAK.MY,DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(TRK,(10,10),RLSE),
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=800)
//STEP2 EXEC PGM=IEFBR14
//STEP3 EXEC PGM=IEFBR14
//STEP4 EXEC PGM=IEFBR14
//STEP5 EXEC PGM=IEFBR14
//STEP6 EXEC PGM=IEFBR14
//STEP7 EXEC PGM=IEFBR14
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
|
and jcl listing is as follows
Code: |
ICH70001I SHRDV02 LAST ACCESS AT 12:55:57 ON FRIDAY, NOVEMBER 15, 2013
IEF202I SHRDV02T STEP1 - STEP WAS NOT RUN BECAUSE OF COND = ONLY
IEF272I SHRDV02T STEP1 - STEP WAS NOT EXECUTED. [/color]
IEF373I STEP/STEP1 /START 2013319.1256
IEF374I STEP/STEP1 /STOP 2013319.1256 CPU 0MIN 00.00SEC SRB 0M
IEF142I SHRDV02T STEP2 - STEP WAS EXECUTED - COND CODE 0000
IEF373I STEP/STEP2 /START 2013319.1256
IEF374I STEP/STEP2 /STOP 2013319.1256 CPU 0MIN 00.01SEC SRB 0M
IEF142I SHRDV02T STEP3 - STEP WAS EXECUTED - COND CODE 0000
IEF373I STEP/STEP3 /START 2013319.1256
IEF374I STEP/STEP3 /STOP 2013319.1256 CPU 0MIN 00.01SEC SRB 0M
IEF142I SHRDV02T STEP4 - STEP WAS EXECUTED - COND CODE 0000
IEF373I STEP/STEP4 /START 2013319.1256
IEF374I STEP/STEP4 /STOP 2013319.1256 CPU 0MIN 00.01SEC SRB 0M
IEF142I SHRDV02T STEP5 - STEP WAS EXECUTED - COND CODE 0000
IEF373I STEP/STEP5 /START 2013319.1256
IEF374I STEP/STEP5 /STOP 2013319.1256 CPU 0MIN 00.01SEC SRB 0M
IEF142I SHRDV02T STEP6 - STEP WAS EXECUTED - COND CODE 0000
IEF373I STEP/STEP6 /START 2013319.1256
IEF374I STEP/STEP6 /STOP 2013319.1256 CPU 0MIN 00.01SEC SRB 0M
IEF236I ALLOC. FOR SHRDV02T STEP7
IEF237I JES2 ALLOCATED TO SYSPRINT
IEF237I JES2 ALLOCATED TO SYSIN
IEF142I SHRDV02T STEP7 - STEP WAS EXECUTED - COND CODE 0000
|
As we clearly seen listing show step1 is not executed due to condition code.
but every one says step1 always executes regardless of any condition. because it treat first step condition as false and execute step1.
Please give suggestion and your valuable comments.
EF202I SHRDV02T STEP1 - STEP WAS NOT RUN BECAUSE OF COND = ONLY
IEF272I SHRDV02T STEP1 - STEP WAS NOT EXECUTED.
thanks in advance.
Deepak kumar |
|
Back to top |
|
|
Pandora-Box
Global Moderator
Joined: 07 Sep 2006 Posts: 1592 Location: Andromeda Galaxy
|
|
|
|
Dear Deepak,
What is your requirement? |
|
Back to top |
|
|
gcicchet
Senior Member
Joined: 28 Jul 2006 Posts: 1702 Location: Australia
|
|
|
|
Hi,
Quote: |
but every one says step1 always executes regardless of any condition. because it treat first step condition as false and execute step1.
Please give suggestion and your valuable comments.
|
Not everyone
ibmmainframes.com/about2457.html
Gerry |
|
Back to top |
|
|
Kmr.deepakcs
New User
Joined: 11 Oct 2013 Posts: 37 Location: India
|
|
|
|
@pandora
I read in ibm manual that first step of job is always executes bt why it will not run by using cond=only....Can u show some light on this...
Deepak |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
Can you provide a link, or example of the relevant text?
COND=ONLY means run the step only if the has been an abend in an earlier step. Since it is the first step, there isn't a previous step, so there hasn't been an abend, so the step does not run.
This may be documented unclearly in the manual, or incorrectly. |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
|
|
|
|
And you can always bypass the first step by coding a RESTART parameter. |
|
Back to top |
|
|
Kmr.deepakcs
New User
Joined: 11 Oct 2013 Posts: 37 Location: India
|
|
|
|
Thanks bill and nic. you guys are very supporting. |
|
Back to top |
|
|
|