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

concatenate two gdgs into a new GDG


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

New User


Joined: 02 Jun 2007
Posts: 5
Location: ireland

PostPosted: Thu Jun 14, 2007 2:07 am
Reply with quote

I have two GDG datasets (both will be the most recent generations), which I need to concatenate to produce a third GDG - how do I do produce this third file?

eg. ABCDEF.G0283V00
123456.G0283V00

I need the contents of both these files in a new generation, ABCDEF.G0284V00


thanks
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: Thu Jun 14, 2007 2:13 am
Reply with quote

Hello,

You might use IEBGENER or SORT.

For the input, concatenate your.dsn(0) and your.dsn(-1) and use your.dsn(+1) as the output dataset name. If you use this approach, you will not need to change the jcl for every run to use the specific version.
Back to top
View user's profile Send private message
Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Thu Jun 14, 2007 11:53 am
Reply with quote

Option #1 if DCB parameters are same

You can use (0) to get current GDG version.
ABCDEF(0)
123456(0)

Option #2 if DCB parameters are different, then code below 2 steps in same job.
copy ABCDEF(0) to new GDG ABCDEF(+1) with DISP=(New,catlg,delete)
copy 123456(0) to same GDG ABCDEF(+1) with DISP=(MOD)

If the GDG are created in same job then you need to use (+1)
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 Concatenate 2 fields (usage national)... COBOL Programming 2
No new posts Rexx to list generations of GDGs and ... CLIST & REXX 3
No new posts concatenate sysin to dsn JCL & VSAM 7
No new posts Need help to concatenate files with w... All Other Mainframe Topics 3
No new posts Concatenate two files of variable rec... DFSORT/ICETOOL 3
Search our Forums:

Back to Top