MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

how to delay rexx code till completion of jcl

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
kanitha-mvs
Beginner


Joined: 17 May 2006
Posts: 26
Topics: 17

PostPosted: Wed May 17, 2006 12:40 pm    Post subject: how to delay rexx code till completion of jcl Reply with quote

hi,
I am submitting a jcl from the rexx program.
only after the completion of the submitted jcl, the remaining rexx code should be executed.
Are there any means to make the rexx program wait till the completion of the submitted jcl?
Back to top
View user's profile Send private message
semigeezer
Supermod


Joined: 03 Jan 2003
Posts: 1014
Topics: 13
Location: Atlantis

PostPosted: Wed May 17, 2006 1:49 pm    Post subject: Reply with quote

This is generally bad program design. Is there a reason that you can not just call the program from Rexx instead of through a batch job?
Back to top
View user's profile Send private message Visit poster's website
Phantom
Data Mgmt Moderator
Data Mgmt Moderator


Joined: 07 Jan 2003
Posts: 1056
Topics: 91
Location: The Blue Planet

PostPosted: Thu May 18, 2006 1:43 am    Post subject: Reply with quote

kanitha,

You can do that. but you will be eating away the CPU unnecessarily. check for other alternatives as semigeezer suggested.

Thanks,
Phantom
Back to top
View user's profile Send private message
semigeezer
Supermod


Joined: 03 Jan 2003
Posts: 1014
Topics: 13
Location: Atlantis

PostPosted: Thu May 18, 2006 3:19 pm    Post subject: Reply with quote

It isn't a CPU issue, since you can use syscalls sleep but an initiator issue and a resource contention issue. You have no gaurentee that your job will even run when you submit it. It could run an hour later, or never run if the initiators are in use or your job is waiting on a data set. And there is the issue of error checking. How do you check for, and recover from errors in the batch job execution? Parse listings? Get SDSF output? Checking for errors, contention, etc is very easy to do right in the Rexx exec.
Back to top
View user's profile Send private message Visit poster's website
kanitha-mvs
Beginner


Joined: 17 May 2006
Posts: 26
Topics: 17

PostPosted: Wed May 24, 2006 11:56 am    Post subject: Reply with quote

Hi,
Thanks for your replies.
What I wanted to know is "Is there any way to find the completion of the jcl in REXX". The job wont take much time. Just to make the code wait for few seconds.
Back to top
View user's profile Send private message
semigeezer
Supermod


Joined: 03 Jan 2003
Posts: 1014
Topics: 13
Location: Atlantis

PostPosted: Wed May 24, 2006 12:12 pm    Post subject: Reply with quote

Even more reason to just allocate the ddnames and call the program from Rexx. Then you just check the rc variable
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group