View previous topic :: View next topic
|
Author |
Message |
Gabriele Soranzo
New User
Joined: 28 Dec 2006 Posts: 6 Location: Italy, Trieste
|
|
|
|
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 |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
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 |
|
|
Gabriele Soranzo
New User
Joined: 28 Dec 2006 Posts: 6 Location: Italy, Trieste
|
|
|
|
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 |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
Back to top |
|
|
mmwife
Super Moderator
Joined: 30 May 2003 Posts: 1592
|
|
|
|
Deleted by the author. Misread Gabriele's requirement. |
|
Back to top |
|
|
Phrzby Phil
Senior Member
Joined: 31 Oct 2006 Posts: 1050 Location: Richmond, Virginia
|
|
|
|
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 |
|
|
gcicchet
Senior Member
Joined: 28 Jul 2006 Posts: 1702 Location: Australia
|
|
|
|
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 |
|
|
sri_mf
Active User
Joined: 31 Aug 2006 Posts: 218 Location: India
|
|
|
|
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 |
|
|
gcicchet
Senior Member
Joined: 28 Jul 2006 Posts: 1702 Location: Australia
|
|
|
|
Hi Sri,
Code: |
IF=(001,0,C' VT50I ')
|
wiil search the entire record.
Gerry |
|
Back to top |
|
|
sri_mf
Active User
Joined: 31 Aug 2006 Posts: 218 Location: India
|
|
|
|
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 |
|
|
gcicchet
Senior Member
Joined: 28 Jul 2006 Posts: 1702 Location: Australia
|
|
|
|
Hi Sri,
Use 0 to scan to the end of the record.
Gerry |
|
Back to top |
|
|
Gabriele Soranzo
New User
Joined: 28 Dec 2006 Posts: 6 Location: Italy, Trieste
|
|
|
|
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 |
|
|
sri_mf
Active User
Joined: 31 Aug 2006 Posts: 218 Location: India
|
|
|
|
gcicchet wrote: |
Hi Sri,
Use 0 to scan to the end of the record.
Gerry |
Thanks gerry. |
|
Back to top |
|
|
gcicchet
Senior Member
Joined: 28 Jul 2006 Posts: 1702 Location: Australia
|
|
|
|
Gabriele,
mio piacere. Ciao.
Gerry |
|
Back to top |
|
|
|