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

How to create GDG generation versions?


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

New User


Joined: 22 Jun 2007
Posts: 42
Location: Chennai

PostPosted: Fri Jan 18, 2008 1:04 pm
Reply with quote

Suppose we have two GDG versions:

XXXXXXX.GB.XXX.FIELDET1.G0001V00
XXXXXXX.GB.XXX.FIELDET1.G0002V00
XXXXXXX.GB.XXX.FIELDET1.G0002V01

If we use
XXXXXXX.GB.XXX.FIELDET1(0)

Then it will return
XXXXXXX.GB.XXX.FIELDET1.G0002V01

If we use
XXXXXXX.GB.XXX.FIELDET1(-1)

Then it will return
XXXXXXX.GB.XXX.FIELDET1.G0001V00

Now my question is we can create the generation as (+1) in JCL,
but how we can create its versions in JCL?
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Fri Jan 18, 2008 1:12 pm
Reply with quote

Ayansau,

Quote:
XXXXXXX.GB.XXX.FIELDET1.G0002V00
XXXXXXX.GB.XXX.FIELDET1.G0002V01

For any generation, only 'one' version exists at any point of time.

Quote:
but how we can create its versions in JCL?

Follow the link for old topic -

ibmmainframes.com/about209.html
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Fri Jan 18, 2008 1:42 pm
Reply with quote

From the fine manual, if you had looked .....

Quote:

In an MVS system-created GDG name, the version number is always be 0. (MVS does not increase the version number by 1 for subsequent versions.) To obtain a version number other than 0, you must explicitly specify the version number (for example, A.B.C.G0004V03) when the data set is allocated. You must also explicitly specify the version number to retrieve a GDG with a version number other than 0.
Back to top
View user's profile Send private message
shreevamsi

Active User


Joined: 23 Feb 2006
Posts: 305
Location: Hyderabad,India

PostPosted: Fri Jan 18, 2008 3:50 pm
Reply with quote

hi,

As of my knowledge, we can't create a GDG version like
XXXXXXX.GB.XXX.FIELDET1.G0002V01 using JCL
It can be only created by renaming.

Usually, the mainframe creates these versions for itz backup purposes only.

~Vamsi
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Fri Jan 18, 2008 4:04 pm
Reply with quote

Vamsi,

Quote:
we can't create a GDG version like
XXXXXXX.GB.XXX.FIELDET1.G0002V01 using JCL

Wrong.

Quote:
It can be only created by renaming.

Its one of the method.

Quote:
the mainframe creates these versions for itz backup purposes only.

Wrong again. Is MF a human being or does it read your mind to backup some files and not others.

Read the link provided (old post) one more time.
Back to top
View user's profile Send private message
ousep143

New User


Joined: 06 Oct 2007
Posts: 32
Location: India

PostPosted: Fri Jan 18, 2008 4:33 pm
Reply with quote

Hi,
Is it possible to update the generation dataset?

Regards
icon_smile.gif
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Fri Jan 18, 2008 4:42 pm
Reply with quote

ousep143,

Quote:
Is it possible to update the generation dataset?

GDG generation is nothing but a flat file. So.....
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: Fri Jan 18, 2008 9:48 pm
Reply with quote

Hello,

Quote:
Is it possible to update the generation dataset?
Typically, new generations are created rather than updating existing generations.

Is there some business reason to "update" an existing generation rather than creating a +1 with the updates?

If you explain your requirement, we may be able to offer suggestions.
Back to top
View user's profile Send private message
ousep143

New User


Joined: 06 Oct 2007
Posts: 32
Location: India

PostPosted: Mon Jan 21, 2008 12:39 pm
Reply with quote

Quote:

If you explain your requirement, we may be able to offer suggestions.


Hi dick,
I want to know,if u update the generation dataset,shall it affect the version number?

Sorry for delay

Regards
icon_smile.gif
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Mon Jan 21, 2008 12:53 pm
Reply with quote

O,

Quote:
if u update the generation dataset,shall it affect the version number?

No.
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Mon Jan 21, 2008 5:32 pm
Reply with quote

Quote:
I want to know,if u update the generation dataset,shall it affect the version number?

There is often some confusion in the terminology used.

Do you really mean the version number or the generation number ?
Back to top
View user's profile Send private message
ousep143

New User


Joined: 06 Oct 2007
Posts: 32
Location: India

PostPosted: Tue Jan 22, 2008 10:05 am
Reply with quote

Quote:
Do you really mean the version number or the generation number ?


hi
Version Number


Regards
icon_smile.gif
Back to top
View user's profile Send private message
the_gautam

Active User


Joined: 05 Jun 2005
Posts: 165
Location: Bangalore

PostPosted: Tue Jan 22, 2008 4:40 pm
Reply with quote

in order to create the generation with the version number different from existing one, you need to give the complete DD NAME "XXXXXXX.GB.XXX.FIELDET1.G0002V01" in the dsn. and not (+1).
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: Tue Jan 22, 2008 8:28 pm
Reply with quote

Hello,

Quote:
I want to know,if u update the generation dataset,shall it affect the version number
No, but I am still not sure i understand just what you need to accomplish.

If you intend to "update" some existing physical file, you will over-write it (destroying the orignal content). This is almost always undesirable. . .

What business requirement is there that makes updating the existing generation (or version) of the data acceptable?

As has already been mentioned, if you use version, use of the data becomes more tedious (which probably means more error prone).

If you explain what is actually needed, someone may have suggestions. It is rather unlikely that your requirement is "brand new" icon_smile.gif
Back to top
View user's profile Send private message
ousep143

New User


Joined: 06 Oct 2007
Posts: 32
Location: India

PostPosted: Wed Jan 23, 2008 10:06 am
Reply with quote

Hi dick,
I want to just know,it will affect the version number or not. Anyway thanks for information.

Regards
icon_smile.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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts How to create a list of SAR jobs with... CA Products 3
No new posts DFHPI1008 JSON generation failed COBOL Programming 0
No new posts Started task using a generation dataset JCL & VSAM 7
No new posts create rexx edit Macro that edits the... CLIST & REXX 3
No new posts COBOL - create and write to output fi... COBOL Programming 0
Search our Forums:

Back to Top