ZDLCDATE clarification



IBM's Command List programming language & Restructured Extended Executor

ZDLCDATE clarification

Postby Viswanathchandru » Fri May 11, 2012 1:24 am

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
Viswanathchandru
 
Posts: 271
Joined: Mon Oct 25, 2010 2:24 pm
Has thanked: 25 times
Been thanked: 0 time

Re: ZDLCDATE clarification

 

Re: ZDLCDATE clarification

Postby Akatsukami » Fri May 11, 2012 1:35 am

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.
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1053
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: ZDLCDATE clarification

Postby Viswanathchandru » Fri May 11, 2012 1:49 am

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
Viswanathchandru
 
Posts: 271
Joined: Mon Oct 25, 2010 2:24 pm
Has thanked: 25 times
Been thanked: 0 time

Re: ZDLCDATE clarification

Postby Akatsukami » Fri May 11, 2012 2:10 am

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.
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1053
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: ZDLCDATE clarification

Postby Viswanathchandru » Fri May 11, 2012 2:17 am

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
Viswanathchandru
 
Posts: 271
Joined: Mon Oct 25, 2010 2:24 pm
Has thanked: 25 times
Been thanked: 0 time

Re: ZDLCDATE clarification

Postby Akatsukami » Fri May 11, 2012 2:23 am

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.
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1053
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: ZDLCDATE clarification

Postby Viswanathchandru » Fri May 11, 2012 2:26 am

Akatsukami,

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

Regards,
V
Viswanathchandru
 
Posts: 271
Joined: Mon Oct 25, 2010 2:24 pm
Has thanked: 25 times
Been thanked: 0 time

Re: ZDLCDATE clarification

Postby steve-myers » Fri May 11, 2012 3:01 am

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.

These users thanked the author steve-myers for the post:
Viswanathchandru (Fri May 11, 2012 3:02 am)
steve-myers
Global moderator
 
Posts: 1886
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 197 times

Re: ZDLCDATE clarification

Postby Viswanathchandru » Fri May 11, 2012 3:04 am

Hello steve,
Is that possible to do a listcat ent to get the creation date through rexx?

Regards,
Viswa
Viswanathchandru
 
Posts: 271
Joined: Mon Oct 25, 2010 2:24 pm
Has thanked: 25 times
Been thanked: 0 time

Re: ZDLCDATE clarification

Postby steve-myers » Fri May 11, 2012 3:13 am

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.

These users thanked the author steve-myers for the post:
Viswanathchandru (Fri May 11, 2012 3:13 am)
steve-myers
Global moderator
 
Posts: 1886
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 197 times


Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post