How to get the MVS command response information.



IBM's Command List programming language & Restructured Extended Executor

How to get the MVS command response information.

Postby nickwyw » Thu Nov 04, 2010 2:08 pm

I want in the REXX, get the volume serial number, used unit address, as follow codes.
I have two question,
first one, in the log I found the command rc = -3, I don't know how to conform the reason.
second, how to set the command response message to a variable, I have tried the OUTTRAP instrcution but it just can get the TSO command message.

49 *-*  address mvs 'D U,,,'unitadd
   >L>    "D U,,,"                 
   >V>    "9001"                   
   >O>    "D U,,,9001"             
   +++ RC(-3) +++                   


Code:
du_command:                               
unitadd = 9001                 
address mvs 'D U,,,'unitadd                                   
if rc \= 0 then do                       
   subrc = rc                             
   say "bad Display unit cmd, rc = "subrc
   subrc = 16                             
   signal end_du_command                 
   end                                   
else do                                   
   say 'the message is '                                 
   end                                   
end_du_command:                           
return subrc                             



Could you give me some advise, Thanks .
nickwyw
 
Posts: 1
Joined: Fri Nov 28, 2008 7:12 pm
Has thanked: 0 time
Been thanked: 0 time

Re: How to get the MVS command response information.

Postby enrico-sorichetti » Thu Nov 04, 2010 2:18 pm

see
http://publibz.boulder.ibm.com/cgi-bin/ ... s/IKJ4BK80
for the whole TSO REXX shebang

and
z/OS V1R2.0-V1R9.0 TSO/E REXX User's Guide
http://publibz.boulder.ibm.com/cgi-bin/ ... 0706113306
z/OS V1R8.0-V1R9.0 TSO/E REXX Reference
http://publibz.boulder.ibm.com/cgi-bin/ ... 0626210253

for the details of the Address <some environment> facilities

anyway for console commands the proper environment is Address CONSOLE

but that is prone to open up a can of worms for authorizations needed
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 3003
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: How to get the MVS command response information.

Postby Pedro » Fri Nov 05, 2010 9:36 am

If you can whip up some assembler code, it might be easier to use the UCBLOOK macro. You can find more information: Programming Authorized Assembler Services Guide
Pedro Vera
User avatar
Pedro
 
Posts: 686
Joined: Thu Jul 31, 2008 9:59 pm
Location: Silicon Valley
Has thanked: 0 time
Been thanked: 53 times

Re: How to get the MVS command response information.

Postby steve-myers » Thu May 02, 2013 11:52 pm

Pedro is correct, though I would use the UCBSCAN COPY macro.
steve-myers
Global moderator
 
Posts: 2105
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 243 times


Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post