Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
REXX Query on ISPF Service

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

New User


Joined: 15 Apr 2009
Posts: 47
Location: Bangalore

PostPosted: Mon Aug 31, 2009 11:16 am    Post subject: REXX Query on ISPF Service
Reply with quote

Hi,
I am a beginner in REXX Programming.
I am dealing with REXX ISPF File Services.

Code:
/*REXX*/       
ADDRESS ISPEXEC
DS1= "HLQ1.FILE1.JCL"
"DSINFO DATASET ("DS1")"
DSDATE = ZDSCDATE
EXIT


Here the file name the REXX search for is MY LOGIN ID as the HLQ and then the File name provided
that is MYLOGINID.HLQ1.FILE1.JCL
So whenever I execute this REXX, it abends... saying the file name specified doesnot exists.
Is there any set up required so that the REXX searches for the correct filr HLQ1.FILE1.JCL instead of MYLOGINID.HLQ1.FILE1.JCL

Please advice
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10327
Location: italy

PostPosted: Mon Aug 31, 2009 11:29 am    Post subject: Reply to: REXX Query on ISPF Service
Reply with quote

instead of
Code:
"DSINFO DATASET ("DS1")"

use
Code:
"DSINFO DATASET ('"DS1"')"
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Mon Aug 31, 2009 12:03 pm    Post subject:
Reply with quote

Or ADDRESS TSO "PROFILE NOPREFIX"

O.
Back to top
View user's profile Send private message
sibi Yohannan

New User


Joined: 15 Apr 2009
Posts: 47
Location: Bangalore

PostPosted: Mon Aug 31, 2009 12:11 pm    Post subject: REXX Query on ISPF Service
Reply with quote

Great Help!!
Thank you, It worked

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

Senior Member


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

PostPosted: Mon Aug 31, 2009 9:13 pm    Post subject: Reply to: REXX Query on ISPF Service
Reply with quote

Quote:
Or ADDRESS TSO "PROFILE NOPREFIX"

This change is global, throughout the TSO user's address space. And I think it persists after logoff. It might affect other programs and will affect the usage of ISPF.

So I think Enrico's suggestion of adding the quotes is a better solution.
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 401
Location: Mumbai

PostPosted: Mon Aug 31, 2009 10:54 pm    Post subject: Reply to: REXX Query on ISPF Service
Reply with quote

This may be picky, but it is better to put the quotes around the data set name rather than in the service call. Though they are functionally the same, it is much clearer (to me, at least) to deal with the TSO naming conventions in one place (assignment) rather than in two (assignment and service calls). Otherwise, if you need to use the same name in more than one place then you will need to change all the places you use it which are errors waiting to happen. So it is better to say
Code:
DS1= "'HLQ1.FILE1.JCL'"
"DSINFO DATASET ("DS1")"
than to say
Code:
DS1= "HLQ1.FILE1.JCL"
"DSINFO DATASET ('"DS1"')"

Also, by fully qualifying the name (using single quotes), your program will work regardless of the TSO PROFILE PREFIX/NOPREFIX setting
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 How to write Rexx program to size and... sreejeshcs CLIST & REXX 14 Thu Oct 12, 2017 7:26 am
No new posts HEX value search in a DB2 query maxsubrat DB2 2 Wed Oct 04, 2017 3:04 pm
This topic is locked: you cannot edit posts or make replies. Rexx to execute spool commands upendrasri CLIST & REXX 5 Wed Oct 04, 2017 6:54 am
This topic is locked: you cannot edit posts or make replies. Rexx to execute spool commands upendrasri CLIST & REXX 47 Fri Sep 29, 2017 1:08 pm
No new posts MQ command in option 6 of ISPF! Vignesh Sid All Other Mainframe Topics 3 Tue Sep 26, 2017 6:01 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us