Page 1 of 2

How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 6:19 pm
by shyamsaravan
Hi;

The Step TEST1 needs to be executed with delay time of 5 minutes for multiple times to avoid the resubmit of the same JCL


//TESTJCL1 JOB (1,2AB,XX-10),'AAAA',MSGCLASS=A,USER=SARETE1 
//TEST1 EXEC TESTWER1,                                               
//           ENV=P,GDP=##,STRPARM=X001####,                         
//           A1AAA011=NNBATCZ0


Can you please give some suggestion to write the JCL

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 6:46 pm
by Robert Sample
JCL is not a programming language with control structures and you cannot loop -- period.

Furthermore, it is extremely bad programming practice to implement any kind of delay in batch programs.

You need to go back to the start and redesign your process since what you want to do (a) is a BAD IDEA, and (b) won't work no matter what you do.

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 6:56 pm
by Anuj Dhawan
It's be nice if you tell us what you want to do, possibly then there can be some practical solution to that. Inducing "delay in batch" on zOS was never a good idea, as Robert has said.

If you just want to change the job-name, possibly REXX can be your choice to generate differnt job-names.

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 7:02 pm
by BillyBoyo
How many places you going to post this?

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 7:16 pm
by shyamsaravan
Thanks for the reply..In our system we dont have REXX tool..in that JCL the proc TESTWER1 will process the 25000 thousand records,but we have to process 20 lakhs records,so that we are resubmitting the same JCL again and again...To aviod this tedious work.,if any other ways to go in jcl..Please.

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 8:09 pm
by Akatsukami
shyamsaravan wrote:Thanks for the reply..In our system we dont have REXX tool..in that JCL the proc TESTWER1 will process the 25000 thousand records,but we have to process 20 lakhs records,so that we are resubmitting the same JCL again and again...To aviod this tedious work.,if any other ways to go in jcl..Please.

Why yes: change TESTWER1 so that it will process all the records.

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 8:16 pm
by shyamsaravan
Thanks..We have the setup like to process the 25000 records only..If we increase means it will get abend some place..so that we restricted to 25K records per one time

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 8:25 pm
by Akatsukami
shyamsaravan wrote:Thanks..We have the setup like to process the 25000 records only..If we increase means it will get abend some place..so that we restricted to 25K records per one time

You mean your shop's 360/195 only has 3 cylinders of DASD available for output? Sounds like you're in a world of trouble, Sunny Jim.

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 8:32 pm
by shyamsaravan
Not like that....it will update to some other DB2 tables and missed some of the rows to be updated..

Re: How to reexecute the step after delay time

PostPosted: Tue Aug 21, 2012 8:36 pm
by prino
shyamsaravan wrote:Not like that....it will update to some other DB2 tables and missed some of the rows to be updated..

Sheesh, what kind of a crap system are you running?