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
 

 

problem with TSO STATUS and TSO OUTPUT commands in REXX

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
nuck

New User


Joined: 09 Dec 2005
Posts: 33

PostPosted: Tue Sep 12, 2006 4:07 pm    Post subject: problem with TSO STATUS and TSO OUTPUT commands in REXX
Reply with quote

Hi all,

I'm encountering a problem that's driving me nuts. In a REXX exec, I submit 1-n jobs, and then query their STATUS (WAITING, EXECUTING, ON OUTPUT), once the status is ON OUTPUT, I issue an OUTPUT command to store the SDSF output into a seq. file.

Problem is, the STATUS indicates that the job is on the output queue, however when I issue the OUTPUT, it comes back with NO HELD OUTPUT FOR JOB and a RC = 0.

What am I doing wrong here?

here's a bit of trace info to illustrate the problem:

961 *-* trace i
962 *-* x = OUTTRAP('JOBS.')
>L> "JOBS."
>F> "JOBS."
963 *-* "STATUS "job_nam.i"("job_num.i")"
>L> "STATUS "
>C> "JOB_NAM.1"
>V> "TCV0006X"
>O> "STATUS TCV0006X"
>L> "("
>O> "STATUS TCV0006X("
>C> "JOB_NUM.1"
>V> "JOB05672"
>O> "STATUS TCV0006X(JOB05672"
>L> ")"
>O> "STATUS TCV0006X(JOB05672)"
964 *-* y = OUTTRAP('OFF')
>L> "OFF"
>F> "OFF"
965 *-* if index(jobs.1,'ON OUTPUT') > 0
>V> "JOB TCV0006X(JOB05672) ON OUTPUT QUEUE"
>L> "ON OUTPUT"
>F> "24"
>L> "0"
>O> "1"
966 *-* then
*-* do
967 *-* say jobs.1
>V> "JOB TCV0006X(JOB05672) ON OUTPUT QUEUE"
JOB TCV0006X(JOB05672) ON OUTPUT QUEUE
968 *-* "OUTPUT "job_nam.i"("job_num.i") PRINT(LCHECK"i
>L> "OUTPUT "
>C> "JOB_NAM.1"
>V> "TCV0006X"
>O> "OUTPUT TCV0006X"
>L> "("
>O> "OUTPUT TCV0006X("
>C> "JOB_NUM.1"
>V> "JOB05672"
>O> "OUTPUT TCV0006X(JOB05672"
>L> ") PRINT(LCHECK"
>O> "OUTPUT TCV0006X(JOB05672) PRINT(LCHECK"
>V> "1"
>O> "OUTPUT TCV0006X(JOB05672) PRINT(LCHECK1"
NO HELD OUTPUT FOR JOB TCV0006X(JOB05672)
969 *-* frc=rc
>V> "0"
Back to top
View user's profile Send private message

nuck

New User


Joined: 09 Dec 2005
Posts: 33

PostPosted: Tue Sep 12, 2006 4:56 pm    Post subject:
Reply with quote

...I think I found the problem.....

I've added a simple delay loop (i.e. do j = 1 to 999) between the STATUS and the OUTPUT command. It would appear that the output from STATUS is not entirely correct, and a small delay is required before the SDSF output can be stored. icon_eek.gif
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Testing rerad cursor for status with ... John F Dutcher DB2 8 Fri May 19, 2017 9:35 pm
This topic is locked: you cannot edit posts or make replies. Need help on If condition continuatio... ashok_uddaraju CLIST & REXX 4 Fri May 19, 2017 8:55 am
No new posts Fileaid 2 commands instream work. In ... descann Compuware & Other Tools 2 Tue May 16, 2017 3:31 pm
No new posts find RACF group for access to spooled... jzhardy JCL & VSAM 1 Mon May 08, 2017 11:46 am
No new posts Running an REXX EXEC implicitly sho7hills CLIST & REXX 3 Thu Apr 20, 2017 8:14 am


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