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

Deleting versions in a GDG


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
akashs

New User


Joined: 24 Nov 2005
Posts: 49
Location: chennai

PostPosted: Sat Apr 25, 2009 7:59 pm
Reply with quote

In a gdg i have 50 generations..i need to delete the last 30 generations .is it possible


regards,
akash
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Sat Apr 25, 2009 9:06 pm
Reply with quote

AFAIK, you have to delete them one by one.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Sat Apr 25, 2009 9:52 pm
Reply with quote

Quote:
you have to delete them one by one.


unless your DSN is in the form for gen number instead of relative
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Sat Apr 25, 2009 9:55 pm
Reply with quote

Or use IDCAMS ALTER to reduce the LIMIT and do it in one quick batch job.
Back to top
View user's profile Send private message
superk

Global Moderator


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

PostPosted: Sun Apr 26, 2009 3:16 am
Reply with quote

Of course, in the amount of time it took the OP to type the question, and then wait for a response, they could've created a list of all the generations, edited it to add the DELETE command in front, and than ran an IDCAMS or TSO job using that data. Would've been all done in about a minute.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Sun Apr 26, 2009 5:06 am
Reply with quote

a simple D line command on a 3.4 would have done it, also.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Sun Apr 26, 2009 9:38 am
Reply with quote

Probably I misunderstood the request, may be some one can help me to understand.

OP says:
Quote:
i need to delete the last 30 generations.
(emphasis added by me) I believe by "last 30" he means . . .starting from 50th, 49th . . .up to 21st generations and if IDCAMS ALTER is used that will "delete" 1st, 2nd . . . up to 30th generations, right? icon_confused.gif
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Sun Apr 26, 2009 1:14 pm
Reply with quote

Anuj D. wrote:
Probably I misunderstood the request, may be some one can help me to understand.

OP says:
Quote:
i need to delete the last 30 generations.
(emphasis added by me) I believe by "last 30" he means . . .starting from 50th, 49th . . .up to 21st generations and if IDCAMS ALTER is used that will "delete" 1st, 2nd . . . up to 30th generations, right? icon_confused.gif

Using ALTER to change the LIMIT will change the number of generations retained in the GDG base. By default the oldest generations will be dropped from the base, thus retaining the latest nn generations.

I read the req as dropping the 30 oldest, but if you are correct, then the OP should have made this abundantly clear.
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Deleting a Tape file JCL & VSAM 14
No new posts CA7 deleting files in steps after job... CA Products 4
No new posts Merge GDG versions JCL & VSAM 5
No new posts TBSARG - Deleting the search criteria... TSO/ISPF 6
No new posts Savings by Deleting Unused datasets All Other Mainframe Topics 13
Search our Forums:

Back to Top