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
 

 

How to search in batch *only on few members* of a PDS?

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

New User


Joined: 28 Dec 2006
Posts: 6
Location: Italy, Trieste

PostPosted: Thu May 08, 2008 7:36 pm    Post subject: How to search in batch *only on few members* of a PDS?
Reply with quote

Hi all,

I have the following requirement.

I have a PDS with several thowsand of members.
I would like do a batch search using ISRSUPC only on members which name starts with a prefix (for example "XX").

If I use the ISPF panel it's easy do to it,
I can specify "MYLIB.A.B.C(XX*)',
but if I use in a Jcl the ISRSUPC utility I see only the NEWDD DD (and here I can specify only 'MYLIB.A.B.C').

How can I restrict the search only on members which name starts with "XX"? using ISRSUPC in a JCL?

Gabriele
Back to top
View user's profile Send private message

superk

Moderator Team Head


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

PostPosted: Thu May 08, 2008 7:47 pm    Post subject: Reply to: How to search in batch *only on few members* of a
Reply with quote

I just went through ISPF Option 3.14 to build a search job for a selected list of members. I got NEWDD pointing to the PDS, OUTDD for the output, and then SYSIN contains the SRCHFOR statement, and a bunch of SELECT statements for the member names.
Back to top
View user's profile Send private message
Gabriele Soranzo

New User


Joined: 28 Dec 2006
Posts: 6
Location: Italy, Trieste

PostPosted: Thu May 08, 2008 8:04 pm    Post subject: Reply to: How to search in batch *only on few members* of a
Reply with quote

Hi superk,

many ythanks for your prompt reply.

It fits almost my requirement (since your solution needs in every case of a ISPF panel, instead I have the need to use directly (and only) JCL, without to pass for a ISPF panel), but for now it is an acceptable workaround.

The last question, if you have time:
do you know if there is a way to specify wildchar * in SELECT of Sysin (I mean, for example : XX*)? Or do SELECT accepts only a list of complete names?

Thanks, Gabriele
Back to top
View user's profile Send private message
superk

Moderator Team Head


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

PostPosted: Thu May 08, 2008 8:15 pm    Post subject: Reply to: How to search in batch *only on few members* of a
Reply with quote

Doesn't look like it:

A.36 SELECT - Select PDS Members.
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Thu May 08, 2008 10:21 pm    Post subject:
Reply with quote

Deleted by the author. Misread Gabriele's requirement.
Back to top
View user's profile Send private message
Phrzby Phil

Active Member


Joined: 31 Oct 2006
Posts: 964
Location: Richmond, Virginia

PostPosted: Fri May 09, 2008 12:58 am    Post subject:
Reply with quote

Once you've used 3.14 to generate the JCL, save it to your own file (e.g., a PDS) - then modify it and run it when you want.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Fri May 09, 2008 9:58 am    Post subject:
Reply with quote

Hi Gabriele,

if you have FILEAID on your system you can try this

Code:
//FILEAID  EXEC PGM=FILEAID           
//SYSPRINT DD SYSOUT=*                 
//SYSLIST  DD SYSOUT=*                 
//DD01     DD DSN=INPUT PDS,           
//            DISP=SHR                 
//SYSIN    DD *                       
$$DD01 LIST MEMBERS=ABC,               
            IF=(001,EQ,C'M')           
$$DD01 LIST MEMBERS=XY,               
            IF=(001,EQ,C'M')           
/*                                     


The above code will scan for members prefixed with ABC and XY.


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

Active User


Joined: 31 Aug 2006
Posts: 216
Location: India

PostPosted: Fri May 09, 2008 12:14 pm    Post subject:
Reply with quote

gcicchet wrote:

//SYSIN DD *
$$DD01 LIST MEMBERS=ABC,
IF=(001,EQ,C'M')
$$DD01 LIST MEMBERS=XY,
IF=(001,EQ,C'M')
/*
Gerry


Hi gerry

"IF=(001,EQ,C'M')".i think this will search for M in the first byte.Correct me if am wrong.
Then how to search for a particular string where we do not know its occurance using File-Aid.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Fri May 09, 2008 12:17 pm    Post subject:
Reply with quote

Hi Sri,
Code:
IF=(001,0,C' VT50I ') 


wiil search the entire record.

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

Active User


Joined: 31 Aug 2006
Posts: 216
Location: India

PostPosted: Fri May 09, 2008 12:22 pm    Post subject:
Reply with quote

gcicchet wrote:
Hi Sri,
Code:
IF=(001,0,C' VT50I ') 


wiil search the entire record.

Gerry


Hi gerry Its working fine.Thanks alot.
Small clarifiaction: "IF=(001,0,C' VT50I ')" what does 0 in bold specifies.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Fri May 09, 2008 12:31 pm    Post subject:
Reply with quote

Hi Sri,
Use 0 to scan to the end of the record.


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

New User


Joined: 28 Dec 2006
Posts: 6
Location: Italy, Trieste

PostPosted: Fri May 09, 2008 2:12 pm    Post subject: Reply to: How to search in batch *only on few members* of a
Reply with quote

Hi all,

my customer has not installed FILEAID, but the workaround of JCL with ISRSUPC created once time it's an acceptable solution for me,

many thanks...and I'm (happily :-) impressed of the right and prompt replies on this forum !,

Gabriele
Back to top
View user's profile Send private message
sri_mf

Active User


Joined: 31 Aug 2006
Posts: 216
Location: India

PostPosted: Fri May 09, 2008 2:19 pm    Post subject:
Reply with quote

gcicchet wrote:
Hi Sri,
Use 0 to scan to the end of the record.


Gerry


Thanks gerry.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Fri May 09, 2008 2:32 pm    Post subject:
Reply with quote

Gabriele,

mio piacere. Ciao.


Gerry
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 Search utility(3.14) using JCl and Cobol RKS3 COBOL Programming 12 Sat Jun 10, 2017 10:24 pm
No new posts HLIST Utility In Batch Virendra Shambharkar TSO/ISPF 4 Fri Apr 07, 2017 3:38 pm
No new posts Batch job tuning sgandhla Testing & Performance analysis 5 Fri Mar 24, 2017 9:41 pm
No new posts MIPS/CPU consumption reduction in Batch vishwakotin DFSORT/ICETOOL 4 Sat Mar 18, 2017 5:46 pm
No new posts Copying Panvalet members to PDS LOGESHWARAN K CA Products 4 Mon Mar 06, 2017 10:45 am


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