Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

To check the new generation of GDG
Goto page 1, 2  Next
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Thu Nov 26, 2009 12:52 pm    Post subject: To check the new generation of GDG
Reply with quote

Hi,

We have a business server which pushes files to GDGs, each time a new file sits in the server it pushes that as a new generation of GDG. The existing process we follow is to check the mails from the server group and then go to the GDG files and find the new generation and process it.

I need some ideas on how best we can finetune the existing process. Like is there a way we can check the creation date of the latest generation and then have it checked with the previous one and if the date is greater we can directly run the job.

Any other alternatives are also appreciated

Sorry for the big story....
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu Nov 26, 2009 12:56 pm    Post subject:
Reply with quote

Although GDG is not recommended for dataset triggering, can you not have words with your scheduling people to trigger the required job at creation of the next generation.

That way you need to do nothing else.
Back to top
View user's profile Send private message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Thu Nov 26, 2009 1:21 pm    Post subject:
Reply with quote

No this is a kind of test job and the scheduling team won't help us in any way
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Thu Nov 26, 2009 10:09 pm    Post subject:
Reply with quote

Hello,

How often are these files uploaded?
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


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

PostPosted: Fri Nov 27, 2009 6:57 pm    Post subject: Reply to: To check the new generation of GDG
Reply with quote

Quote:
We have a business server which pushes files to GDGs, each time a new file sits in the server it pushes that as a new generation of GDG.
What happens to generation once that is processed -- Because you didn't tell this so I'll take the benefit of doubt and suggest why don't you delete the generation when it's processed once...
Back to top
View user's profile Send private message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Mon Nov 30, 2009 2:46 pm    Post subject:
Reply with quote

Sorry for the delayed response, the GDG versions would be kept them after the process
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1445
Location: Azeroth

PostPosted: Mon Nov 30, 2009 3:55 pm    Post subject:
Reply with quote

Hi,

As D requested,

Quote:
How often are these files uploaded?


Based on the interval we can try other options.
Back to top
View user's profile Send private message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Mon Nov 30, 2009 3:57 pm    Post subject:
Reply with quote

Well, the interval for each new generation would be 7 days to 1 month
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Nov 30, 2009 5:30 pm    Post subject:
Reply with quote

Still not totally clear, so is this correct ...........

You want to check the generations of a GDS that are catalogued.
You know the generation that was last processed.
So you want to compare the catalogued generations against the last generation which has been processed.
If the generations are different then process the generations that have not been processed and update the record file that has recorded the last generation processed.
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1445
Location: Azeroth

PostPosted: Mon Nov 30, 2009 5:33 pm    Post subject:
Reply with quote

Expat,

I think ur right with the requirements.
Back to top
View user's profile Send private message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Mon Nov 30, 2009 5:37 pm    Post subject:
Reply with quote

Quote:

You want to check the generations of a GDS that are catalogued.

Yes, I want to check the latest generation of the GDG
Quote:

You know the generation that was last processed

Well, I would not be knowing the exact generation number of the previous generation
Quote:
So you want to compare the catalogued generations against the last generation which has been processed

I just need to know whether the new generation is created today.
Quote:
If the generations are different then process the generations that have not been processed and update the record file that has recorded the last generation processed.

Yes, I need to process the generations which are created newly.

Sorry once again all of you, I was not clear with my requirement. Well, in a way the process itself is hazy...
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1445
Location: Azeroth

PostPosted: Mon Nov 30, 2009 5:57 pm    Post subject:
Reply with quote

Hi,

Try using the below REXX to get the most recent GDG member created.

CICDL.DQ.PRFILE.DISKCOPY is the base of GDG.
DSN1 variable has the latest GDG meber.
My manager is around, so will try the rest of the code later icon_smile.gif

Code:
/*REXX*/                                             
GDG_LINES = 'CICDL.DQ.PRFILE.DISKCOPY'               
FILE1=STRIP(GDG_LINES)                               
GDG = FILE1                                         
DSN = STRIP(GDG!!".G0000V00")                       
X=OUTTRAP(LST.)                                     
" LISTC ENT('"GDG"')"                               
X=OUTTRAP(OFF)                                       
SAY 'LST.0 IS ' LST.0                               
DO A = LST.0 TO 1 BY -1                             
  IF POS('NONVSAM',LST.A) > 0 THEN DO               
    DSN = SUBSTR(LST.A,POS('NONVSAM',LST.A)+13,44)   
    A = 0                                           
END                                                 
END                                                 
DSN1=STRIP(DSN)                                     
SAY ' THE GDG MEMBER TESTED IS ' DSN1               
EXIT   



Hope this helps..
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Nov 30, 2009 6:02 pm    Post subject:
Reply with quote

You can get the date that a dataset was catalogued from IDCAMS LISTCAT, but I would rather use a control dataset that records the generation number last processed. If a generation for some reason is created over a weekend and the job runs after that, then the date will not be equal to the run date. Also, the file arrives at 23:59:59, your job runs 00:00:01 and again the dates are different, so no run.

What happens if two generations are created on the same day. At least with a control file that option is also covered.
Back to top
View user's profile Send private message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Mon Nov 30, 2009 6:06 pm    Post subject:
Reply with quote

Hi Vasanth,
Is DSN1 the new GDG generation??

Hi Expat,
I tried LISTCAT but then as u said the complexity is more, so I dropeed the idea of LISTCAT and about control files, could you throw some more light??

Thanks,
Ravi
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Nov 30, 2009 6:18 pm    Post subject:
Reply with quote

Read control file to find last generation number processed

Perform LISTCAT on GDG base.
Parse LISTCAT information.
If Generation number GT control file -
Build JCL with this generation number
Loop back to parse LISTCAT
If Another generation then concatenate i/p files and loop back again
Else submit job

Job will also conditionally update the control file with highest generation number processed.
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1445
Location: Azeroth

PostPosted: Mon Nov 30, 2009 6:20 pm    Post subject:
Reply with quote

Hi,

Quote:
Is DSN1 the new GDG generation??


Yes it is. Just give it a try at your shop with a test GDG and confirm what data it fetches.

I really think Expat's concerns are very valid. And you may have to address them if you feel that they may hit you.
If you still feel that you need the creation date, try using DSINFO utility to get the creation date.
the variable ZDSCDATE has the date.

Code:
ISPEXEC  DSINFO DATASET(dsname)

+---------------+-------------------------------------------+-----------+-----
| ZDSCDATE      | Creation date (National format)           | Character |   10
+---------------+-------------------------------------------+-----------+-----
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Nov 30, 2009 6:43 pm    Post subject:
Reply with quote

Mmmmmmmmmmmmmm, using DSINFO will cause migrated generations to be recalled and then remigrated overnight, and will probably be noticed by your friendly storage management team who will investigate the HSM (or whatever) "thrashing" of the generations and then possibly arrive at your desk for a little (un)friendly chat.

P.S. Do not believe everything written about storage guys on this forum turning up with baseball bats, we prefer rubber tubing filled with lead shot as it leaves a lot less visible evidence icon_lol.gif
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1445
Location: Azeroth

PostPosted: Mon Nov 30, 2009 6:54 pm    Post subject:
Reply with quote

Quote:
DSINFO will cause migrated generations to be recalled and then remigrated overnight


Oops, I think I forgot an important piece of code in my last suggestion.

Code:
**Conditions Apply**
icon_biggrin.gif
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Mon Nov 30, 2009 6:57 pm    Post subject:
Reply with quote

my experience with irritated storage guys is,
they talk to their buddies in TSO administration
and suddenly your userid is invalid and it takes forever to get it reinstated
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1445
Location: Azeroth

PostPosted: Mon Nov 30, 2009 7:09 pm    Post subject:
Reply with quote

Hi Expat,

Could you pls let me know, will LISTCAT recall the dataset if its migrated?

Thanks,
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Goto page 1, 2  Next
Page 1 of 2

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts What is the command to check MODE of ... rohanthengal CLIST & REXX 6 Fri Nov 18, 2016 1:48 pm
No new posts Check System time(Minute) Using TIME1... balaji81_k DFSORT/ICETOOL 5 Fri Nov 11, 2016 10:53 am
No new posts Random Password (in string format) ge... ezhavendhan COBOL Programming 10 Mon Aug 29, 2016 3:18 pm
No new posts Syntax to check the first 4 digits of... kshirabdhi DFSORT/ICETOOL 10 Tue May 03, 2016 12:21 pm
No new posts Check special resource availability w... pinimo JCL & VSAM 8 Fri Apr 15, 2016 8:18 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us