IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How to search a member in a PDS


IBM Mainframe Forums -> Mainframe Interview Questions
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
arvindkumarbhardwaj

New User


Joined: 12 Jan 2007
Posts: 4
Location: bangalore

PostPosted: Thu Apr 12, 2007 5:02 pm
Reply with quote

I have i have a requirement. I have a member name which i have to search in many pds say like 25 pds. How i can find in which pds the member is.I know how to to search string in pds but i have to search the member only not straing and print the PDS name.
plz help me with code.

plz seggest me any REXX tool or JCL for the same
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Apr 12, 2007 5:36 pm
Reply with quote

The cynic in me sort of says HOMEWORK.

Here's a quick way of listing out the members of a PDS, so having this to work with you can wrap the rest of the code around it and get it to do what you want. It's based on a single PDS name, but I'm sure you'll be able to get around that.
Code:

/* REXX */               
PDS = "'your pds name'"         
X=OUTTRAP(LIST.)         
"LISTDS " PDS " MEM "     
X=OUTTRAP(OFF)           
SAY LIST.0 - 6           
X = MSG('OFF')           
                         
DO A = 7 TO LIST.0       
   SAY LIST.A             
END                       
Back to top
View user's profile Send private message
superk

Global Moderator


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

PostPosted: Thu Apr 12, 2007 6:01 pm
Reply with quote

I'm just sitting here thinking that the easiest way is to use ISPF option 3.4 to list all of the PDS's, then type "M member" on the COMMAND line. ISPF will then indicate the PDS or PDS's where "member" resides.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Apr 12, 2007 6:12 pm
Reply with quote

As I said, the cynic in me .....................

Why the need to print the dataset name I'm still working on.

Quote:
plz seggest me any REXX tool or JCL for the same

That's why I went for the REXX hint.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Thu Apr 12, 2007 6:17 pm
Reply with quote

STFM ( search the friendly web ) for ISRDDN
read the IBM web doc or if You are at 2.10 level of os/390 You should find
it in the ISPF manuals
Back to top
View user's profile Send private message
srebba
Warnings : 1

New User


Joined: 26 Apr 2007
Posts: 37
Location: USA

PostPosted: Fri Jun 01, 2007 11:41 pm
Reply with quote

Hi,

My mainframe support the below command

Go to 3.4

Please search(put the PDS name) with starting common name.
Eg. WOT.NIKE.* and press enter
U will be able to see all data set with the above stating names.

Now in the Commond line write MEMEBER PROG1 and enter.
This is will take you to the PDS wchich containt the above program PROG1

Please let me know once get it

Thank you
Sree
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Sat Jun 02, 2007 10:15 pm
Reply with quote

Hi Arvind,

You can try this:
Code:
//SEARCH  EXEC PGM=ISRSUPC,
//            PARM=(SRCHCMP,'ANYC')
//NEWDD  DD DSN=PA.PROD.SRCLIB,DISP=SHR
//       DD DSN=PA.TEST.SRCLIB1,DISP=SHR
//       DD DSN=PA.TEST.SRCLIB2,DISP=SHR
//       .
//       .
//       .
//       DD DSN=PA.TEST.SRCLIBn,DISP=SHR
//OUTDD  DD SYSOUT=*
//SYSIN  DD *
SRCHFOR  'my-string'
SELECT mymod
//

You may need quotes around mymod (I don't remember).
Back to top
View user's profile Send private message
kranthikumarb

Active User


Joined: 02 Jan 2009
Posts: 115
Location: Hyderabad

PostPosted: Thu Jan 08, 2009 5:51 pm
Reply with quote

I really dont understand why do we need to explicitly write a JCL for this. (No offence meant).

One can search using 3.14 option using batch by selecting the execution mode as batch (option 2 ). However this will automatically create a JCL for you.


Please correct me if I am wrong
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Thu Jan 08, 2009 10:09 pm
Reply with quote

Hello,

Please note that this topic has been inactive for a year and a half. . .

It is best to reply to current, active topics icon_wink.gif
Back to top
View user's profile Send private message
Terry Heinze

JCL Moderator


Joined: 14 Jul 2008
Posts: 1249
Location: Richfield, MN, USA

PostPosted: Thu Jan 08, 2009 10:26 pm
Reply with quote

Arvind is now 2 years older, may have had several employers since Jan, 2007, and might not even be reading this bulletin board anymore. icon_lol.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> Mainframe Interview Questions

 


Similar Topics
Topic Forum Replies
No new posts Search two or more word with FILEAID Compuware & Other Tools 15
No new posts Sortjoin and Search for a String and ... DFSORT/ICETOOL 1
No new posts first column truncated in search result IBM Tools 13
No new posts ISRSUPC search utility - using high l... TSO/ISPF 2
No new posts To search DB2 table based on Conditio... DB2 1
Search our Forums:

Back to Top