Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Is it possible to execute other steps if it abended

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
subbubannurutcs

New User


Joined: 15 Oct 2006
Posts: 11

PostPosted: Sun Oct 22, 2006 11:55 am    Post subject: Is it possible to execute other steps if it abended
Reply with quote

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
View user's profile Send private message

diwa_thilak

Active User


Joined: 13 Jul 2006
Posts: 205
Location: At my desk

PostPosted: Sun Oct 22, 2006 2:45 pm    Post subject:
Reply with quote

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
View user's profile Send private message
priyesh.agrawal

Senior Member


Joined: 28 Mar 2005
Posts: 1452
Location: Chicago, IL

PostPosted: Mon Oct 23, 2006 6:49 am    Post subject: Re: Is it possible to execute other steps if it abended
Reply with quote

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
View user's profile Send private message
diwa_thilak

Active User


Joined: 13 Jul 2006
Posts: 205
Location: At my desk

PostPosted: Mon Oct 23, 2006 8:17 am    Post subject:
Reply with quote

Thanks priyesh for correcting me.

Thanks,
Diwakar.D
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Mon Oct 23, 2006 3:03 pm    Post subject:
Reply with quote

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
View user's profile Send private message
vrexy

New User


Joined: 19 May 2005
Posts: 7
Location: bangalore

PostPosted: Thu Oct 26, 2006 11:47 am    Post subject:
Reply with quote

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
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Thu Oct 26, 2006 2:08 pm    Post subject:
Reply with quote

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
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 755
Location: Germany

PostPosted: Fri Oct 27, 2006 12:37 pm    Post subject:
Reply with quote

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
View user's profile Send private message
toddnugen

New User


Joined: 01 Nov 2006
Posts: 9

PostPosted: Wed Nov 01, 2006 7:45 am    Post subject: Re: Is it possible to execute other steps if it abended
Reply with quote

//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
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts IDMS DC027007 T58 TASK:ADS2 PROG:ADSO... gpowell382 IDMS/ADSO 2 Fri Jun 30, 2017 11:52 pm
No new posts Execute TSO ACF commands from COBOL-I... supreethi.srid TSO/ISPF 0 Tue Feb 21, 2017 5:19 pm
No new posts execute APP if they are not ADDRESS T... italo_pm CLIST & REXX 3 Fri Aug 12, 2016 2:15 am
No new posts Execute multiple DB2 Load commands in... faizm DB2 4 Wed Aug 03, 2016 12:53 pm
No new posts CEXEC not able to execute if no SLINE... boyti ko CLIST & REXX 2 Wed Apr 13, 2016 4:31 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us