Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

PANVALET REXX

561 views
Skip to first unread message

FAISAL ZAHIR

unread,
Apr 2, 2002, 2:26:57 AM4/2/02
to
I need to write a rexx program which will give me a list of members in a
panvalet library, with the input being as wildcards like 'auo*', 'amb??a',
etc. Can anyone give any ideas. How do i read a panvalet library from rexx ?

Thanks

Faisal

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to LIST...@VM.MARIST.EDU with the message: INFO TSO-REXX

FAISAL ZAHIR

unread,
Apr 2, 2002, 7:18:04 AM4/2/02
to
I am trying to write rexx to get a list of programs starting with some
prefix and prepare a JCL using the member list. But the members are in
panvalet, so I want to figure out how I can get a list of members in
panvalet, thru rexx

Faisal

-----Original Message-----
From: Alan A John [mailto:alan....@aexp.com]
Sent: Tuesday, April 02, 2002 4:36 PM
To: faisal...@tcscal.co.in
Subject: Re: PANVALET REXX

Can you tell me exactly what you re trying to do ??

Jeremy C B Nicoll

unread,
Apr 2, 2002, 9:06:31 AM4/2/02
to
In article <NFBBIOKMLFNKEKDEAJDF...@tcscal.co.in>,

FAISAL ZAHIR <faisal...@TCSCAL.CO.IN> wrote:
> I need to write a rexx program which will give me a list of members in
> a panvalet library, with the input being as wildcards like 'auo*',
> 'amb??a', etc. Can anyone give any ideas. How do i read a panvalet
> library from rexx ?

I'd assume you use the relevant PAN#1 or PAN#2 (or whatever utility
program). In JCL that's something like:

//STEPn EXEC PGM=PANVALET
//SYSPRINT ...
//SYSIN ...

You don't say if you want to do this in foreground or batch... If the
latter run a normal PAN#n step and put the results in a temporary dataset
and then read that in the rexx exec in the next step. If foreground
you'd need to use ALLOCATEs to allocate the SYSPRINT and SYSIN and
perhaps results datasets if they have other names, then call th utility
program, so something like:

/* REXX */

address TSO

"allocate fi(sysprint) reuse unit(vio) recfm(f b) lrecl(121) ..."

"allocate fi(sysin) vio catlg recfm(f b) lrecl(80) ..."
card.1 = " sysin statement 1"
card.2 = " sysin statement 2"
card.0 = 2
"execio * diskw sysin (stem card. finis"

"PAN#1" ; prc = rc

if prc == 0 then do
whatever
end

You need to reallocate sysprint to the terminal afterwards.

Can't remember exact syntax of any of that, posting from home.

HTH

--
Jeremy C B Nicoll - my opinions are my own.

Rupert Reynolds

unread,
Apr 2, 2002, 11:38:22 AM4/2/02
to
In-Reply-To: <NFBBIOKMLFNKEKDEAJDF...@tcscal.co.in>
I think that there is a Panvalet utility program which you should be
able to call from Rexx.

I have never done this, but it should be a good start.

Roo

Schwarzbauer, Joe

unread,
Apr 3, 2002, 12:45:54 PM4/3/02
to
Faisal,

Did you get what you needed? We use Panvalet here and I
have done some work in this regard.

for a REXX interface I use pan#2

here is some sample code:
/*********************************************************************
* *
* Get_Pan1 populates panmem.num stem variable with members found *
* on PRODPAN. caller has to parse member names from panmem. stem. *
* *
********************************************************************/*
Get_Pan1: Procedure expose panmem. panuser.,
numprog prog. numincl incl. prodpan
svaddr = ADDRESS() /* save address so I can change it back later */

Address TSO
X = OUTTRAP('OUT.',1) /* avoid error messages from free */

"FREE FI(SYSPRINT,SYSPUNCH)"
"ALLOCATE FI(SYSPRINT) RECFM(F,B) LRECL(133) BLKSIZE(0) NEW DELETE"
"ALLOCATE FI(SYSPUNCH) RECFM(F,B) LRECL(80) BLKSIZE(0) NEW DELETE"
If rc > 0 then signal NoGet /* need sysprint and syspunch */

"NEWSTACK"
Do i = 1 to numincl
If incl.i <> "" Then
Do
QUEUE "++PRINT 0-UP,NAME="incl.i
End
End
Do i = 1 to numprog
If prog.i <> "" Then
Do
QUEUE "++PRINT 0-UP,NAME="prog.i
End
End

QUEUE /* empty record to mark the end of the queue */

"ALLOCATE FI(TEMP) DA(RELPRODB) RECFM(F,B) LRECL(80) BLKSIZE(0) MOD DELETE",

" REUSE" /* this allocate/free deletes the sysin dataset */

"FREE FI(TEMP)"

"ALLOCATE FI(SYSIN) DA(RELPRODB) RECFM(F,B) LRECL(80) BLKSIZE(0) NEW KEEP",

" REUSE" /* I keep this around for error diagnosis */

If rc > 0 then signal NoGet /* i need sysin too */

"EXECIO * DISKW SYSIN (FINIS)" /* write ++print cards to sysin dataset */

If rc > 0 then signal NoGetD

"DELSTACK"

"ALLOCATE FI(SYSIN) da(relprodb) reuse"

"ALLOCATE FI(PANDD1) DSN('"prodpan"') SHR" /* this is my input library */

PARM = "OPEN=INP" /* this tells panvalet to open the library input-only */

ADDRESS LINKMVS "PAN#2" "PARM"

PANRC = rc

"FREE FI(PANDD1,SYSIN) "

"ALLOC FI(SYSIN) DA(*) REUSE " /* allocate sysin to the terminal */

X = OUTTRAP("OFF")

/*copy the 0-up listing to a stem variable */
"EXECIO * DISKR SYSPUNCH (STEM PANMEM. FINIS)"
"FREE FI(SYSPRINT,SYSPUNCH)"
"ALLOC FI(SYSPRINT) DA(*)"
X = OUTTRAP('OFF')
ADDRESS svaddr /* restore address context */
return panrc /* return with pan#2 return code */

Joe Schwarzbauer
jschwa...@unitrin.com

Reliable Life Insurance
Systems Department
231 W. Lockwood Ave.
St Louis Mo 63119

314-968-4910 ext. 6296

Wheaton, Matthew D.

unread,
Apr 3, 2002, 12:23:52 PM4/3/02
to
I wrote a REXX function in ASM that provides 0-Up listing of panvalet
library member names, or provides a listing of a single member (with or
without expanded includes) into
a REXX stem variable.

Wheaton, Matthew D.

unread,
Apr 3, 2002, 3:23:56 PM4/3/02
to
I wrote a REXX function in ASM that provides 0-Up listing of panvalet
library member names, or provides a listing of a single member (with or
without expanded includes) into
a REXX stem variable.

Source is available. It uses Panvalet Access Method (PAM) and thus saves,
ALLOC, DEALLOC, EXECIO, etc.

usage example: Call Panaccs 'STEMXX.','MYPANLIB.NAME','Q1','Q7','P'
would list 0-up all members with names Q1xxxxxxxx to Q7xxxxxxxx, with status
PROD from panvalet library MYPANLIB.NAME in stem variables STEMXX.1 to
STEMXX.n where STEMXX.0 would contain the value of n.

FAISAL ZAHIR

unread,
Apr 4, 2002, 12:01:25 AM4/4/02
to
Thanks a lot ! this should help me immensely,

Faisal

-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-...@VM.MARIST.EDU]On Behalf
Of Schwarzbauer, Joe
Sent: Wednesday, April 03, 2002 9:10 PM
To: TSO-...@VM.MARIST.EDU
Subject: Re: PANVALET REXX

Message has been deleted

ravikant...@gmail.com

unread,
Apr 6, 2014, 11:35:20 PM4/6/14
to
I am also trying to run a rexx which will export/RETRIEVE a panvalet member to a PDS and later import/STORE the member from that PDS back to the panvalet.

I was able to do it in batch using the PAN#n programs but I would like to do this using REXX as foreground process. If possible I would like to avoid the ALLOC's/IO's. I have come across the PAN Command processor which uses the subcommands ADD, RETRIEVE, STORE.

I am not sure if I have to instantiate this PAN command processor environment before using these commands; and how I could do that? (LIBDEF's) may be.

Also any sample code to demonstrate how to leverage these commands is greatly appreciated.

Thanks in advance.
0 new messages