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
 

 

Rexx- SYSDSN - MSG(OFF) issue

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

New User


Joined: 06 Dec 2007
Posts: 7
Location: India

PostPosted: Wed Aug 06, 2008 12:07 pm    Post subject: Rexx- SYSDSN - MSG(OFF) issue
Reply with quote

I trying verify if the dataset is Archive or not using below rexx.
For this i am issing SYSDSN as below and to avoid the messages i am also setting MSG("OFF") but when i run the Rexx it gives me the messages like "DMS2987 CA DISK HAS ARCHIVED
DMS2971 DO YOU WANT TO RESTORE THE DATA SET? (Y/N) "

/*rexx*/
DATASET = "userid.test.input"
MSGSTAT = MSG("OFF")
IF SYSDSN(DATASET) = "DATASET NOT FOUND" THEN DO
SAY "DATASET NOT FOUND"
END
Back to top
View user's profile Send private message

dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Wed Aug 06, 2008 1:08 pm    Post subject:
Reply with quote

someone else will be able to provide the exact line, but to turn messages off in a REXX script I remember something like:

ADDRESS TSO CONTROL MSGNO ...................................


but, this may be something that can not be turned off - don't know.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed Aug 06, 2008 1:48 pm    Post subject:
Reply with quote

Looks as though it may be because the dataset that you are trying to interrogate is 'Archived'. It is a message issued by the ILM software and not REXX.

To avoid this, I usually use LISTDSI instead of SYSDSN because it has a NORECALL parameter.
Code:

/*REXX*/                           
SAY "HLQ PLEASE"                   
PARSE PULL HLQ                     
                                   
  A = "'"STRIP(HLQ)"'"             
  Q = LISTDSI(A NORECALL)           
  SAY "RC = "Q ",REASON = "SYSREASON


LISTDSI is well documented, but unfortunately I just for the life of me can not remember where icon_redface.gif
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Wed Aug 06, 2008 1:54 pm    Post subject:
Reply with quote

Hi,

if you are trying to see if the dataset is migrated or not, I would use the LISTDSI command like LISTDSI 'filename' DIRECTORY NORECALL,

and use the SYSREASON variable to determine the dataset availability.

SYSDN will recall the dataset.


Gerry
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Wed Aug 06, 2008 1:56 pm    Post subject:
Reply with quote

Hi Expat,

I can't type quick enough. icon_lol.gif


Gerry
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1531
Location: Andromeda Galaxy

PostPosted: Wed Aug 06, 2008 1:58 pm    Post subject:
Reply with quote

Expat and PKG23,

Please check the manual TSO/E CLISTs (SA22-7781-04)

http://publib.boulder.ibm.com/infocenter/zos/v1r9/index.jsp?topic=/com.ibm.zos.r9.ikjb800/listdsi.htm

It has all the details about LISTDSI

Thanks,
Prem
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed Aug 06, 2008 2:40 pm    Post subject:
Reply with quote

gcicchet wrote:
Hi Expat,
I can't type quick enough. icon_lol.gif
Gerry

I won't ask why that is icon_lol.gif
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Wed Aug 06, 2008 2:41 pm    Post subject:
Reply with quote

I was born at an early age icon_wink.gif


Gerry
Back to top
View user's profile Send private message
pkg23

New User


Joined: 06 Dec 2007
Posts: 7
Location: India

PostPosted: Wed Aug 06, 2008 2:45 pm    Post subject: Reply to: Rexx- SYSDSN - MSG(OFF) issue
Reply with quote

Great the RECALL option worked. But when i run the rexx, it waits till i press "ENTER". Any idea how we can avoid this.

X = LISTDSI(DATASET DIRECTORY NORECALL)
SAY SYSREASON

Thanks
Prashant
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2025
Location: Silicon Valley

PostPosted: Wed Aug 06, 2008 11:01 pm    Post subject: Reply to: Rexx- SYSDSN - MSG(OFF) issue
Reply with quote

Quote:
Please check the manual TSO/E CLISTs (SA22-7781-04)

Actually, I think you want to read about LISTDSI in the TSO/E Rexx Reference manual.

Quote:
it waits till i press "ENTER". Any idea how we can avoid this.

When you use the SAY instruction, the system waits for the user to read and dismiss your text. If the system did not wait for the user, it would be so fast the user would not have time to read it.

Seems like you are doing this in ISPF, try something like this:
Code:
zerrsm = "not found"                   
zerrlm =  DATASET "was not found"
zerrhm = '*'                               
zerralrm = 'YES'                           
Address ISPEXEC "SETMSG MSG(ISRZ002)"   
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
This topic is locked: you cannot edit posts or make replies. Calling REXX code from ISPF panel sanchita dey TSO/ISPF 4 Mon Jan 02, 2017 5:13 pm
No new posts REXX DB2: Dynamic allocation of DB2.D... BHAS CLIST & REXX 3 Mon Dec 19, 2016 8:26 pm
No new posts find particular member name in PDS us... ravi243 CLIST & REXX 10 Mon Dec 19, 2016 6:44 pm
No new posts Execessive parameter issue Sumeendar JCL & VSAM 5 Mon Dec 19, 2016 4:35 pm
No new posts What is the command to check MODE of ... rohanthengal CLIST & REXX 7 Fri Nov 18, 2016 1:48 pm


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