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
 

 

Rexx code for finding out generations of a GDG

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
Zubbu

New User


Joined: 18 Oct 2007
Posts: 1
Location: Hyderabad

PostPosted: Fri Oct 19, 2007 4:33 pm    Post subject: Rexx code for finding out generations of a GDG
Reply with quote

Can anybody provide me the Rexx code for the following requirement.

If we give the GDG base name then all available genrstions of that particular GDG file should should be written to an output file.

Ex: when I Give TY205.TEST.GDG and it has 3 generations say

TY205.TEST.GDG.G0001V00
TY205.TEST.GDG.G0002V00
TY205.TEST.GDG.G0003V00

Then the Output file should contain.

TY205.TEST.GDG
TY205.TEST.GDG.G0001V00
TY205.TEST.GDG.G0002V00
TY205.TEST.GDG.G0003V00
Back to top
View user's profile Send private message

superk

Moderator Team Head


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

PostPosted: Fri Oct 19, 2007 4:42 pm    Post subject: Reply to: Rexx code for finding out generations of a GDG
Reply with quote

See any of these previous topics:

http://ibmmainframes.com/viewtopic.php?t=23862
http://ibmmainframes.com/viewtopic.php?t=24353
http://ibmmainframes.com/viewtopic.php?t=24879
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Sat Oct 20, 2007 12:44 am    Post subject: Reply to: Rexx code for finding out generations of a GDG
Reply with quote

Code:

//DDNAME DD DISP=SHR,DSN=gdg_name

Jcl will treat Your dsn specification as if You ad concatenated all
the gdg versions

//DDNAME DD DISP=SHR,DSN=gdg_name(0)
//       DD DISP=SHR,DSN=gdg_name(-1)
//       DD DISP=SHR,DSN=gdg_name(-2)
//       DD DISP=SHR,DSN=gdg_name(...)
//       DD DISP=SHR,DSN=gdg_name(...)
//       DD DISP=SHR,DSN=gdg_name(-n)


so no need to use additional tools to achieve what You want

Code:

//GENRSTEP EXEC PGM=IEBGENER
//SYSPRINT   DD SYSOUT=*
//SYSIN      DD DUMMY
//SYSUT1     DD DISP=SHR,DSN=gdg_base_name
//SYSUT2     DD DISP=(NEW....)
//              DSN=all_gdg_data,
//              allocation_parameters


the jcl above with the obvious adjustment will accumulate all the
versions of a gdg in a single dataset
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts MAX-RC 88 and Return code 606 in DFH0... lind sh CICS 1 Tue Jan 24, 2017 1:23 pm
No new posts How to Capture the Max return code of... anilkumar922 All Other Mainframe Topics 0 Thu Jan 12, 2017 12:02 pm
This topic is locked: you cannot edit posts or make replies. Calling REXX code from ISPF panel sanchita dey TSO/ISPF 4 Mon Jan 02, 2017 5:13 pm
No new posts REXX DB2: Dynamic allocation of DB2.D... BHAS CLIST & REXX 3 Mon Dec 19, 2016 8:26 pm
No new posts find particular member name in PDS us... ravi243 CLIST & REXX 10 Mon Dec 19, 2016 6:44 pm


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