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
 

 

Extract PDS name from ISREDIT

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
View previous topic :: :: View next topic  
Author Message
vvmanyam

New User


Joined: 16 Apr 2008
Posts: 86
Location: Bangalore

PostPosted: Thu Mar 05, 2009 7:20 pm    Post subject: Extract PDS name from ISREDIT
Reply with quote

Hi friends
How to get the PDS name from which the rexx command is executed in the rexx program.
Say if we execute a rexx command from a
PDS mem: TEXT.DATASET(MEMBER)
I go in to that pds and give the command 'TSO TESTREX' on the command line.
Now how to extract the PDS name 'TEXT.DATASET(MEMBER)' in the TESTREX program.

Thanks,
Balu
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: Thu Mar 05, 2009 7:51 pm    Post subject:
Reply with quote

Take a look at PARSE SOURCE in the manual.

Search the forum for examples of the same question.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Thu Mar 05, 2009 8:05 pm    Post subject: Reply to: Extract PDS name from ISREDIT
Reply with quote

Maybe I'm interpreting this topic wrong, but from what I can see that won't work. I don't know of any way to tie the name of a dataset that you're currently "in" (your term. I presume that means that it's opened in an ISPF Browse/Edit/View session) to an exec running in the TSO/E address space.

In order to get the results that I believe you want, that exec is going to have to be included as part of an ISPF Edit macro, which will know both the name of the dataset and the member (if it's a PDS) that you currently have open. There are many examples of this posted here.
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: Thu Mar 05, 2009 8:17 pm    Post subject:
Reply with quote

As stated above
Code:

/* REXX ***                          */         
PARSE SOURCE . . C . E .                       
IF C <> '?'                                     
   THEN SAY 'YOU ARE EXECUTING ' E||'('||C||')'
   ELSE SAY 'YOU ARE EXECUTING ' E             
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10231
Location: italy

PostPosted: Thu Mar 05, 2009 9:21 pm    Post subject: Reply to: Extract PDS name from ISREDIT
Reply with quote

Code:
Address ISREDIT "(DATASET) = DATASET"
Address ISREDIT "(MEMBER)  = MEMBER"
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 401
Location: Mumbai

PostPosted: Thu Mar 05, 2009 11:24 pm    Post subject: Reply to: Extract PDS name from ISREDIT
Reply with quote

Figured you'd have to find the allocations so I did a google search for "rexx parse source ddname" and found this. It looks like what was asked for. Don't know if it works but it looks OK.

trivia: it looks like none of the solutions will work for execs compiled to link edited modules because parse source doesn't work the same from link edited module execs.
Back to top
View user's profile Send private message
vvmanyam

New User


Joined: 16 Apr 2008
Posts: 86
Location: Bangalore

PostPosted: Fri Mar 06, 2009 10:27 am    Post subject:
Reply with quote

I thnak all of you for your response

expat,
I have tried that by using 'PARSE SOURCE' but the soulution isn't working
'C' --> which is the member name is extracted properly
but the PDS name 'E' is only a question mark.

enrico-sorichetti,
Your solution is working perfectly

MBabu:
I have tried the solution in the link provided. It is too big and looks too complicated. But I just tried to exectue and surprisingly its working icon_biggrin.gif

Any how my problem is solved, thanks again

Regrads,
Balu
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 -> TSO/ISPF All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Extract set of records matching on ac... bhaskar_kanteti DFSORT/ICETOOL 3 Mon Mar 06, 2017 7:19 am
No new posts Sort Logic to extract data scorp_rahul23 DFSORT/ICETOOL 13 Tue Mar 01, 2016 1:22 am
No new posts how to extract the member name ? jackzhang75 CLIST & REXX 1 Wed Feb 17, 2016 9:21 pm
No new posts Extract specific step spool data enrico-sorichetti JCL & VSAM 1 Thu Feb 04, 2016 9:48 am
No new posts ISREDIT - Position Cursor on the Comm... Tarique Anwer TSO/ISPF 5 Wed Feb 03, 2016 12:44 pm


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