To take backup of all the GDG versions



IBM's Command List programming language & Restructured Extended Executor

To take backup of all the GDG versions

Postby sambathjai21 » Thu Nov 21, 2013 7:11 pm

Hi Friends,

I would like to know whether it's possible to take backup of all the GDG versions as a flat file?

For eg: If I provide the GDG base 'WXX080.CA99DH01.M.CONTROL.FILE.*' as input and the GDG contains some 5 version as shown below.
WXX080.CA99DH01.M.CONTROL.FILE.G0001V00
WXX080.CA99DH01.M.CONTROL.FILE.G0002V00
WXX080.CA99DH01.M.CONTROL.FILE.G0003V00
WXX080.CA99DH01.M.CONTROL.FILE.G0004V00
WXX080.CA99DH01.M.CONTROL.FILE.G0005V00

Whether it's possible to this 5 versions as backup in 5 flat files using REXX code?
sambathjai21
 
Posts: 3
Joined: Thu Nov 21, 2013 6:55 pm
Has thanked: 0 time
Been thanked: 0 time

Re: To take backup of all the GDG versions

Postby NicC » Thu Nov 21, 2013 7:16 pm

Why Rexx? Why not simply use IEBGENER or Sort?
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 3025
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 136 times

Re: To take backup of all the GDG versions

Postby Robert Sample » Thu Nov 21, 2013 7:20 pm

First, you need to know that terminology is critical in IT where similar terms may mean very different things. And what you called "versions" in your post are actually "generations". Versions will be G1234V01, G1234V02, and so forth -- the generation number is the same and the version number is different. Note that only one version of a generation can be cataloged at a time, so creating G1234V01 means G1234V00 will be uncataloged.

Second, if you don't care about sequencing you can use the GDG base name, which allows you to pull in each generation starting with the newest and going to the oldest. If you care about sequencing, you will need to genreate a list of the generations (using IDCAMS or other tool of your choice) and create JCL (or code) to process them in the proper sequence.
Robert Sample
Global moderator
 
Posts: 3720
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times


Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post