Page 1 of 1

ZDLCDATE clarification

PostPosted: Fri May 11, 2012 1:24 am
by Viswanathchandru
Dear all,

I'm trying to get the date on which it was created. I tried initially with a flat file and I was able to get it. But i'm not able to get the date of creation for a GDG. Are there any specific keyword to display the date of creation for GDG? Below is the code i tried. Please let me know if i need to give any more information on this. Apologize if i or my thoughts are wrong!

 ***************************** Top of Data **************************
 /*REXX*/                                                           
 TRACE ?R                                                           
 DSN = "SYSK.KOL.xxxxxx"                             
 ADDRESS ISPEXEC                                                     
 "LMDINIT LISTID(TMPID) LEVEL("DSN")"                               
 "LMDLIST LISTID("TMPID") OPTION(LIST) DATASET(DSVAR) STATS(YES)"   
 SAY ZDLCDATE                                                       


Here
SYSK.KOL.xxxxxx
is a GDG. Please advice.
Regards,
Viswa

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 1:35 am
by Akatsukami
Viswanathchandru wrote:Dear all,

I'm trying to get the date on which it was created. I tried initially with a flat file and I was able to get it. But i'm not able to get the date of creation for a GDG. Are there any specific keyword to display the date of creation for GDG? Below is the code i tried. Please let me know if i need to give any more information on this. Apologize if i or my thoughts are wrong!

 ***************************** Top of Data **************************
 /*REXX*/                                                           
 TRACE ?R                                                           
 DSN = "SYSK.KOL.xxxxxx"                             
 ADDRESS ISPEXEC                                                     
 "LMDINIT LISTID(TMPID) LEVEL("DSN")"                               
 "LMDLIST LISTID("TMPID") OPTION(LIST) DATASET(DSVAR) STATS(YES)"   
 SAY ZDLCDATE                                                       


Here
SYSK.KOL.xxxxxx
is a GDG. Please advice.
Regards,
Viswa

Note that SYSK.KOL.SUMFING is a generation data group, which is a catalog entry, not a data set, and which will therefore not have a creation date returned in ZDLCDATE. SYSK.KOL.SUMFING.G1234V00, OTOH, is a data set.

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 1:49 am
by Viswanathchandru
Hello akatsukami, Even i tried with a GDG dataset name and i was not able to get the output i mean the date. Please advice

Regards,
Viswa

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 2:10 am
by Akatsukami
Strange; it works fine for me, either with an absolute (e.g., G1234V00) or relative (e.g., (0)) generation number. Please show the trace that your script generates.

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 2:17 am
by Viswanathchandru
hello akatsukami,

here is the trace output. where u can find the quotes alone without the dates.

  4 *-* ADDRESS ISPEXEC                                                     
                                                                           
  5 *-* "LMDINIT LISTID(TMPID) LEVEL("DSN")"                               
    >>>   "LMDINIT LISTID(TMPID) LEVEL(SYSK.KOL.xxxxxx.DAILY.G0002V00)"   
                                                                           
  6 *-* "LMDLIST LISTID("TMPID") OPTION(LIST) DATASET(DSVAR) STATS(YES)"   
    >>>   "LMDLIST LISTID(ISR00002) OPTION(LIST) DATASET(DSVAR) STATS(YES)"
                                                                           
  7 *-* SAY ZDLCDATE                                                       
    >>>   "          "                                                     


Regards,
V

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 2:23 am
by Akatsukami
Viswanathchandru wrote:hello akatsukami,

here is the trace output. where u can find the quotes alone without the dates.

  4 *-* ADDRESS ISPEXEC                                                     
                                                                           
  5 *-* "LMDINIT LISTID(TMPID) LEVEL("DSN")"                               
    >>>   "LMDINIT LISTID(TMPID) LEVEL(SYSK.KOL.xxxxxx.DAILY.G0002V00)"   
                                                                           
  6 *-* "LMDLIST LISTID("TMPID") OPTION(LIST) DATASET(DSVAR) STATS(YES)"   
    >>>   "LMDLIST LISTID(ISR00002) OPTION(LIST) DATASET(DSVAR) STATS(YES)"
                                                                           
  7 *-* SAY ZDLCDATE                                                       
    >>>   "          "                                                     


Regards,
V

Is that generation migrated? I would expect that result if that were so. Check first with the SYSDSN function.

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 2:26 am
by Viswanathchandru
Akatsukami,

The mentioned GDG's are in Tape. Will that be a problem for this. Apologizes if i'm wrong!

Regards,
V

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 3:01 am
by steve-myers
Yes. There are just two ways to obtain the creation date for a dataset on tape.
  • From the label for the dataset on the tape. This most likely cannot be done in TSO. A batch job would require a very specialized program to access the tape label.
  • From the records of the tape manager at your site.
The catalog entry for the dataset may have a creation date, but its reliability is questionable.

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 3:04 am
by Viswanathchandru
Hello steve,
Is that possible to do a listcat ent to get the creation date through rexx?

Regards,
Viswa

Re: ZDLCDATE clarification

PostPosted: Fri May 11, 2012 3:13 am
by steve-myers
Viswanathchandru wrote:Hello steve,
Is that possible to do a listcat ent to get the creation date through rexx?

Regards,
Viswa
You can OUTTRAP the output from a LISTCAT command and scan it.