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

GDG merge


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

New User


Joined: 03 Aug 2009
Posts: 25
Location: Singapore

PostPosted: Tue Apr 26, 2011 5:51 pm
Reply with quote

Hi All
Is it possible to merge all the generations of 3 GDG base if one of the base do not have any generation
eg
1. abc.xyz1 (it has two generation)
2. abc.xyz2 (it has one generation)
3. abc.xyz3 (it do not have generation)

While I was trying with SORT it was giving error message 'NO DATASETS ARE ASSOCIATED WITH BASE' abc.xyz3

Regards,
Samim
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Tue Apr 26, 2011 5:54 pm
Reply with quote

Did the job fail, or was the message informational.

Which sort product are you using.
Back to top
View user's profile Send private message
samimaktar

New User


Joined: 03 Aug 2009
Posts: 25
Location: Singapore

PostPosted: Tue Apr 26, 2011 7:07 pm
Reply with quote

Hi Expat
Job is failing with JCL error(SORT SORTIN +010 - DATA SET NOT FOUND), Product is SORT only(PGM=SORT).
Back to top
View user's profile Send private message
daveporcelan

Active Member


Joined: 01 Dec 2006
Posts: 792
Location: Pennsylvania

PostPosted: Tue Apr 26, 2011 7:14 pm
Reply with quote

You need to create an empty +1 generation to each gdg to ensure there is at least one generation.

A single IEFBR14 step will work before your 'merge' step.

As far as I know, there is no other option (I am sure you will ask anyway).
Back to top
View user's profile Send private message
Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Tue Apr 26, 2011 7:32 pm
Reply with quote

I second you Dave..
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Tue Apr 26, 2011 7:42 pm
Reply with quote

I agree with Dave. For SORT products, when GDG does not have any member attached to it - it's similar to the situation wehre you have concatenated DSNs and one of them is not present, which will apprantely throw 'DATA SET NOT FOUND' message.

Just for experiment, I try:
Code:
//STEP001  EXEC PGM=SORT                 
//SORTIN DD DSN=HLQ.FIRST.GDG,DISP=SHR   
//       DD DSN=HLQ.SECOND.GDG,DISP=MOD   
//SORTOUT DD SYSOUT=*                     
//SYSIN DD *                             
  OPTION COPY                             
//SYSOUT DD SYSOUT=*                     
but this also does not work.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Tue Apr 26, 2011 7:44 pm
Reply with quote

Product is NOT SORT - it is likely to be either DFSORT or SYNCSORT although other sort products are available. PGM=SORT is an alias for the real sort executable. Look at the sort messages - they will tell you.
Back to top
View user's profile Send private message
daveporcelan

Active Member


Joined: 01 Dec 2006
Posts: 792
Location: Pennsylvania

PostPosted: Tue Apr 26, 2011 7:46 pm
Reply with quote

Vegas Line : 3 to 1 we will not hear from this TS.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Tue Apr 26, 2011 7:54 pm
Reply with quote

Quote:
Product is SORT only(PGM=SORT).

Quote:
Product is NOT SORT - it is likely to be either DFSORT or SYNCSORT although other sort products are available. PGM=SORT is an alias for the real sort executable. Look at the sort messages - they will tell you.
Ditto.

*POSE*

Sometimes I really wonder -- what is that very first word The SORT representatives have after seeing such comments from an OP, specially when we have kernal writers also around...icon_smile.gif
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Tue Apr 26, 2011 8:33 pm
Reply with quote

Anuj Dhawan wrote:
For SORT products, when GDG does not have any member attached to it

Anuj, you must be working too hard using terminology like this icon_lol.gif
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Tue Apr 26, 2011 10:20 pm
Reply with quote

LOL, not really expat - my syntax-check tool gave me those words:

Code:
//STEP001  EXEC PGM=SORT                                               
//SORTIN DD DSN=HLQ.FIRST.GDG,DISP=SHR                             
//SORTIN DD DSN=HLQ.FIRST.GDG,DISP=SHR                             
CAY6099W GENERATION DATA GROUP "HLQ.FIRST.GDG" SPECIFIED WITHOUT A
         GENERATION NUMBER - ALL MEMBERS SELECTED                     
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Tue Apr 26, 2011 11:36 pm
Reply with quote

Quote:
any member attached to it


maybe expat was referring to another of the poorly chosen technical terms?
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Wed Apr 27, 2011 5:01 am
Reply with quote

Hi,


Quote:
Is it possible to merge all the generations of 3 GDG base if one of the base do not have any generation
- the answer is NO

Quote:
You need to create an empty +1 generation to each gdg to ensure there is at least one generation.

as long as you don't roll off a needed generation

Quote:
Job is failing with JCL error(SORT SORTIN +010 - DATA SET NOT FOUND), Product is SORT only(PGM=SORT).

How do you get +010 when you are only concatenating 3 GDG base.

Also I'm sure you mean concatenating and NOT merging.


Gerry
Back to top
View user's profile Send private message
samimaktar

New User


Joined: 03 Aug 2009
Posts: 25
Location: Singapore

PostPosted: Wed Apr 27, 2011 9:38 am
Reply with quote

Hi All
Thanks for your discussion on the topic.
@gcicchet:
1. Is there any other way to merge all the generations of 3 GDG base if one of the base do not have any generation without using SORT ?
2. Yes,I was trying to do it using DD Concatenation.


Regards,
Samim
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Wed Apr 27, 2011 10:04 am
Reply with quote

Hi Samin,



Quote:
1. Is there any other way to merge all the generations of 3 GDG base if one of the base do not have any generation without using SORT ?
The answer is still no regardless of which program/utility you use.

In JES2, allocation of datasets required by a step are done prior to step executing.


Gerry
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Wed Apr 27, 2011 10:07 am
Reply with quote

Why do you have an empty GDG base in the first place?

To by-pass the problem you can list the GDG bases using IDCAMS, process the output and set a return code based on what you find. You can then conditionally execute a) a step with all 3 GDG bases concatenated or b) another step with only those bases with associated datasets. I'll leave you to work out how many steps you would require - it is too early in the morning for me.
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 Merge two VSAM KSDS files into third ... JCL & VSAM 6
This topic is locked: you cannot edit posts or make replies. Merge 2 input files based on the reco... JCL & VSAM 2
No new posts Merge 2 input files after sort SYNCSORT 14
No new posts Merge files with a key and insert a b... DFSORT/ICETOOL 6
No new posts Merge 2 lines based on Space from a S... DFSORT/ICETOOL 5
Search our Forums:

Back to Top