View previous topic :: View next topic
|
Author |
Message |
subbubannurutcs
New User
Joined: 15 Oct 2006 Posts: 11
|
|
|
|
Q : The JOB consists of 5 steps if the job abended at 3 rd step then the other steps nothing but 4 th and 5 th steps will execute or not |
|
Back to top |
|
|
diwa_thilak
Active User
Joined: 13 Jul 2006 Posts: 205 Location: At my desk
|
|
|
|
subbubannurutcs,
The job will not will not execute the remaining steps if the step has abended due to logical errors in the programs(i.e Data access violation, S22).
But if the job has abended to dataset not found/ catalogues. Empty dataset we can use the return codes to run the other steps.
Simple words:
cobol errors: if Abend no resuming, that logic has to be included in Code.
JCL errors : Use return code to execute other steps.
Correct me if i am wrong.
Thanks,
Diwakar .
Nobody is perfect. I am Nobody |
|
Back to top |
|
|
priyesh.agrawal
Senior Member
Joined: 28 Mar 2005 Posts: 1448 Location: Chicago, IL
|
|
|
|
subbu... COND=EVEN can be used to execute further step even if a preceding step has abended.
There are some constraints which needs to be consider for this type of execution... look here for more details...
Quote: |
cobol errors: if Abend no resuming, that logic has to be included in Code.
JCL errors : Use return code to execute other steps. |
Diwakar... See what manual says on this...
Quote: |
If a step abnormally terminates during scheduling, due to failures such as JCL errors or the inability to allocate space, the system bypasses the remaining steps, no matter what the COND parameter requests. |
|
|
Back to top |
|
|
diwa_thilak
Active User
Joined: 13 Jul 2006 Posts: 205 Location: At my desk
|
|
|
|
Thanks priyesh for correcting me.
Thanks,
Diwakar.D |
|
Back to top |
|
|
Bitneuker
CICS Moderator
Joined: 07 Nov 2005 Posts: 1104 Location: The Netherlands at Hole 19
|
|
|
|
In addition to what priyesh said:
If you want a step to be executed when a prior step abende code COND=ONLY. This step will only be executed if the job abended. Often done for recovery of a database. |
|
Back to top |
|
|
vrexy
New User
Joined: 19 May 2005 Posts: 7 Location: bangalore
|
|
|
|
Hi ,
Suppose 3 steps are there in 1st step is having one member , this member is used by 2nd step . if that member is empty in 1st step 2nd step should not run . it should go directly to the 3rd step , can u please let me know how to check the empty file using JCL and how to put condition.
Surya |
|
Back to top |
|
|
Bitneuker
CICS Moderator
Joined: 07 Nov 2005 Posts: 1104 Location: The Netherlands at Hole 19
|
|
|
|
vrexy wrote: |
Hi ,
Suppose 3 steps are there in 1st step is having one member , this member is used by 2nd step . if that member is empty in 1st step 2nd step should not run . it should go directly to the 3rd step , can u please let me know how to check the empty file using JCL and how to put condition.
Surya |
Step 1 is the one to set the condition depending on the content of the member. I.e. when empty set condition to 1, when not set condition to 2. How to do this you can find in the application programming manuals yourself. In the JCL at step 2 and 3 you code the COND parameter. Keep in mind that the COND condition is used to find out if the step is to be not executed. If the member is empty at step 2 code COND,EQ,1; if step 1 set the condition to 1 this step will not run. If not at step 3 code COND,NE,2 |
|
Back to top |
|
|
UmeySan
Active Member
Joined: 22 Aug 2006 Posts: 771 Location: Germany
|
|
|
|
Hi !
You could also use the IF Instruction in JCL. It's a bit more comfortable.
// IF (RC EQ 4) THEN
//*
//STEP100 EXEC PGM=IEBGENER
//SYSPRINT DD SYSOUT=*
//SYSIN DD DUMMY
//SYSUT1 DD DISP=SHR,DSN=IER1337.MDL50310.S307.PROTDAT
//SYSUT2 DD SYSOUT=*
//*
// ENDIF
//*
Regards, UmeySan |
|
Back to top |
|
|
toddnugen
New User
Joined: 01 Nov 2006 Posts: 9
|
|
|
|
//Step1 cond=(0,lt)
...
//Step3 cond=(0,lt)
//Step4 cond=(0,lt)
//Step5 cond=(0,lt)
...
//***Operator response If Abend***
//Stepx cond=(0,eq,step4) |
|
Back to top |
|
|
|