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 

To find the job return code submitted thru Rexx

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


Joined: 26 May 2004
Posts: 16
Topics: 6

PostPosted: Fri Nov 25, 2005 8:18 am    Post subject: To find the job return code submitted thru Rexx Reply with quote

Hello,

I have a Rexx tool which will submit a Job.

This job creates an output file, which i need to use it in the same rexx tool down the line.

The problem is
Immediately after submitting the job, next step starts executing and by that time the output file is not created.

Is there any way to hold the rexx tool execution till the job completes.

Regards,
Selva.
_________________
Thanks,
Zelwaa

-what matters most is how u c urself!!!
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
semigeezer
Supermod


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

PostPosted: Fri Nov 25, 2005 9:51 am    Post subject: Reply with quote

Theoretically, yes it is easy (sleep, check, sleep, check...) but this is very poor design because you never can be sure when your job will execute. If there are limited initiators, it could be a long wait. If there are no initiators, the job might never run. And if there are errors in the job, you have no way of handling them. It is much better to run the program(s) currently in the job directly from within your Rexx. If this is an online tool, it should be completely online. There may be cases where submitting a job and waiting for the output is reasonable, but they are pretty rare and usually involve submitting jobs from an external source, or they involve some program that will only run in batch (usually due to some dependency on the different TCB structure that exists in batch vs TSO).

Try to do it all online if you can (alloc ddnames and call the program). If that doesn't work, either use the Unix sleep command, the LE sleep module (IL0Wait or something like that) or your own sleep module (which is only a few lines of assembler, or there are many examples of robust ones here).

By the way, please search before posting. This topic has been discussed many times before.
Back to top
View user's profile Send private message Visit poster's website
amit4u79
Beginner


Joined: 24 Oct 2005
Posts: 109
Topics: 36
Location: India

PostPosted: Fri Nov 25, 2005 9:21 pm    Post subject: Reply with quote

Hey Zelwaa,

Pls look at the below link :

http://mvsforums.com/helpboards/viewtopic.php?t=5209

Thanks,
Amit Joshi.
_________________
I did not fail; I have found 10,000 ways that would not work - Albert Einstein.
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
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