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

Rex Code for comparioson of PDS contents


IBM Mainframe Forums -> CLIST & REXX
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Kamlesh Kamal

New User


Joined: 16 May 2008
Posts: 36
Location: Kolkata,India

PostPosted: Sun Nov 01, 2009 4:51 pm
Reply with quote

Hi,
Can ayonne help me with a rex piece of code which can do the following.

I will give two separate PDS names and it should give me the names of the members in those PDS'es which is common in both.
PS:I have no REX experience so the code should be complete in all sence.
Thanks a milion in advance.It will be a great help.Also the command to eecute it.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Sun Nov 01, 2009 5:30 pm
Reply with quote

use the ISPF option 3.12 to perform your compare.

The ISPF for z/OS Library will provide you a link to all the relevant manuals that you will need to digest to develop REXX experience.

REXX Reference
REXX User Guide
REXX Docs via IBM Library Server


anyone who knows REXX would not have written 'a piece REX(sic) of code' to satisfy your requirement.

again, it is REXX and they are known as scripts, not code.
Back to top
View user's profile Send private message
Kamlesh Kamal

New User


Joined: 16 May 2008
Posts: 36
Location: Kolkata,India

PostPosted: Sun Nov 01, 2009 5:37 pm
Reply with quote

Hey Dick,

I got your point but I don't have time as of now to familiarize myself with REXX through manuals.So can you help me with the REXX script which can give me common names of two sepate PDS? if that's not much of an effort for you.

for example names common in between the E0421T.FCAE.PL4.JOBS.PKG712
and E0421T.FCAE.PL4.JOBS.PKG640


Code:
sssssssssssssssssssssssssssssssssssssssssssss
Y090    VIEW      E0421T.FCAE.PL4.JOBS.PKG712
Command ===>                                 
           Name     Prompt       Size   Creat
_________ E04214BP *Viewed         20  2009/0
_________ E04214FP *Viewed         19  2009/0
_________ E04214IP *Viewed         24  2009/1
_________ E042149P *Viewed         23  2009/0
_________ E0421U3P                 23  2009/0
_________ E0421U4P                 22  2009/0
_________ E04214AP                 16  2009/0




Code:
Menu  Functions  Confirm  Utilities  Help     
sssssssssssssssssssssssssssssssssssssssssssssssss
Y090    VIEW      E0421T.FCAE.PL4.JOBS.PKG640   
Command ===>                                     
           Name     Prompt       Size   Created 
_________ E0421L1P                 12  2009/05/26
_________ E0421L2P                 11  2009/05/26
_________ E0421L3P                 11  2009/05/26
_________ E0421L4P                 11  2009/05/26
_________ E0421L5P                 11  2009/05/26
_________ E04211OP                 19  2009/10/03
_________ E04211PP                 13  2009/10/03
_________ E04211QP                 14  2009/10/03
_________ E04211RP                 22  2009/10/13
_________ E04211SP                 19  2009/10/13
_________ E04211TP                 20  2009/10/13
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Sun Nov 01, 2009 5:39 pm
Reply with quote

if you don't have time, use ISPF option 3.12 which will provide you with the info that you need.

and as I said, I never bothered to waste my time writing a REXX Script to do what 3.12 does.

so, I can't supply you with any code.
Back to top
View user's profile Send private message
Pedro

Global Moderator


Joined: 01 Sep 2006
Posts: 2547
Location: Silicon Valley

PostPosted: Sun Nov 01, 2009 9:21 pm
Reply with quote

Quote:
I don't have time as of now to familiarize myself with REXX through manuals.

Sorry, but this is not the 'do it for me' forum.
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Sun Nov 01, 2009 10:16 pm
Reply with quote

And I am sure that some hints and tips have been given before in the forum for a similar topic.
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: Mon Nov 02, 2009 3:08 am
Reply with quote

Hello,

Quote:
I don't have time as of now to familiarize myself with REXX through manuals.
If this matters to you, you will find the time. . .

As was posted, you can get what you say you want without writing any REXX. . .
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 400
Location: Mumbai

PostPosted: Mon Nov 02, 2009 4:51 am
Reply with quote

This isn't really a bad way to learn rexx, but what you may want to learn is how to call other programs and then read the output. So one way to do this is to use SuperC online to figure out what options you need to pass it and then write a Rexx program that calls superc (program ISRSUPC, see the manuals on what it takes as input), and then read the the listing using EXECIO. That will give you both experience with using Rexx to do different, common tasks, and it will give you a program that does what you first wanted to have.

The other way to do it is to get the members, create a stem variable with the member names in PDS 1 as tails and then run through the members in PDS 2 checking to see if a tail with each name exists in your stem variable. That should not be more than about 20 lines of code, but I'll leave it to you to write. You can get the pds member names using either the LISTD command from TSO or using some ISPF services (among other ways).
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Mon Nov 02, 2009 4:11 pm
Reply with quote

Quote:
I don't have time as of now to familiarize myself with REXX through manuals.


that' s very sad... I do not have the time either icon_evil.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 -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts run rexx code with jcl CLIST & REXX 15
No new posts Compile rexx code with jcl CLIST & REXX 6
No new posts REXX code to expand copybook in a cob... CLIST & REXX 2
No new posts VSAM return code 23 - for a Random read COBOL Programming 4
No new posts Monitoring production job progress. N... JCL & VSAM 4
Search our Forums:

Back to Top