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

Creation date of a GDG File


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

New User


Joined: 10 Jan 2006
Posts: 76
Location: Germany

PostPosted: Fri Dec 08, 2006 3:43 pm
Reply with quote

Any ISPF Service which I can use to get the creation date of a GDG File?
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Fri Dec 08, 2006 5:51 pm
Reply with quote

At DSLIST use S for info.
Back to top
View user's profile Send private message
antonrino.b

New User


Joined: 10 Jan 2006
Posts: 76
Location: Germany

PostPosted: Fri Dec 08, 2006 6:21 pm
Reply with quote

I need to get the creation date through REXX. Is there any ISPF service to get that?
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Fri Dec 08, 2006 6:37 pm
Reply with quote

Well, mentioning that in the subject and/or posting on the rexx list might have helped.

You might pm superk and ask him/her to help......
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Fri Dec 08, 2006 6:43 pm
Reply with quote

Nevermind, I see that you have your answer ..... icon_smile.gif
Quote:
Yes, DSINFO. Thereafter it's in zdscdate
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Fri Dec 08, 2006 8:16 pm
Reply with quote

The ISPF Service that I believe would be of use is the LMDLIST Service.

If STATS(YES) is specified, the following variables are returned to the variable pool:

ZDLVOL
Volume serial.

ZDLDEV
Device type.

ZDLDSORG
Data set organization.

ZDLRECFM
Record format.

ZDLLRECL
Logical record length.

ZDLBLKSZ
Block size.

ZDLSIZE
Data set size in tracks.

ZDLSIZEX
Data set size in tracks, long format (12 bytes).

ZDLUSED
Percentage of used tracks or pages (PDSE).

ZDLEXT
Number of extents used.

ZDLEXTX
Number of extents used, long format (5 bytes).

ZDLCDATE
Creation date.

ZDLEDATE
Expiration date.

ZDLRDATE
Date last referenced.

ZDLMIGR
Whether the data set is migrated (YES or NO) based on the value of the VOLUME_OF_MIGRATED_DATA_SETS keyword in the ISPF configuration table. If the volume name of the data set matches the value of VOLUME_OF_MIGRATED_DATA_SETS, ZDLMIGR is set to YES, otherwise it is set to NO.

ZDLDSNTP
Dsname type (PDS, LIBRARY, or ' ').

ZDLSPACU
Space units.

ZUDMVOL
Whether the data set is multivolume (Y) or not (N).
Back to top
View user's profile Send private message
antonrino.b

New User


Joined: 10 Jan 2006
Posts: 76
Location: Germany

PostPosted: Fri Dec 08, 2006 9:15 pm
Reply with quote

Thanks Superk. LMDLIST works fine.
Back to top
View user's profile Send private message
prafull

New User


Joined: 08 Dec 2006
Posts: 48

PostPosted: Mon May 19, 2008 12:09 pm
Reply with quote

Hi

one doubt if these commands work for TAPE files too...?
Means if yes then, how can I implement it?

Please help out... icon_sad.gif
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Mon May 19, 2008 2:50 pm
Reply with quote

Don't think they will work for tape ......

But did you try before posting. If so what was the result ?
If not - go and try it now.

Also this thread might help too - but you will need to change the job and unfortunattely that means you doing some research into SMF & DFSORT.

http://www.ibmmainframes.com/viewtopic.php?t=30725&sid=242403552a9b489e0ebe87c8efd9d9f4
Back to top
View user's profile Send private message
prafull

New User


Joined: 08 Dec 2006
Posts: 48

PostPosted: Mon May 19, 2008 4:19 pm
Reply with quote

I had already tried out for TAPE datasets,
It doesn't work.
So I wanted to know if any other option avaliable.
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Tue May 20, 2008 12:37 pm
Reply with quote

Try this, it's something I've posted before somewhere ...........

Batch REXX, you need a CATIN DD statement with the HLQ.** that you want to find out about.
Code:

/* REXX ** CREATION DATE OF GDG DATASET    */         
SIGNAL ON SYNTAX NAME ERR                                                       
"EXECIO * DISKR CATIN ( STEM CAT. FINIS"                                       
DO KCNT = 1 TO CAT.0                                                           
KEY = SUBSTR(CAT.KCNT,1,44)                                                     
MODRSNRC = SUBSTR(' ',1,4)                                                     
CSIFILTK = SUBSTR(KEY,1,44)                                                     
CSICATNM = SUBSTR(' ',1,44)                                                     
CSIRESNM = SUBSTR(' ',1,44)                                                     
CSIDTYPS = 'H               '                                                   
CSICLDI  = SUBSTR('Y',1,1)                                                     
CSIRESUM = SUBSTR(' ',1,1)                                                     
CSIS1CAT = SUBSTR(' ',1,1)                                                     
CSIRESRV = SUBSTR(' ',1,1)                                                     
CSINUMEN = '0002'X                                                             
CSIFLD1  = 'DSCRDT2 '                                                           
CSIFLD2  = 'VOLSER  '                                                           
CSIOPTS  = CSICLDI !! CSIRESUM !! CSIS1CAT !! CSIRESRV                         
CSIFIELD = CSIFILTK !! CSICATNM !! CSIRESNM !! CSIDTYPS !! CSIOPTS             
CSIFIELD = CSIFIELD !! CSINUMEN !! CSIFLD1 !! CSIFLD2                           
WORKLEN = 4096                                                                 
DWORK = '00001000'X !! COPIES('00'X,WORKLEN-4)                                 
RESUME = 'Y'                                                                   
CATNAMET = SUBSTR(' ',1,44)                                                     
DNAMET = SUBSTR(' ',1,44)                                                       
DO WHILE RESUME = 'Y'                                                           
 ADDRESS LINKPGM 'IGGCSI00  MODRSNRC  CSIFIELD  DWORK'                         
 RESUME = SUBSTR(CSIFIELD,150,1)                                               
 USEDLEN = C2D(SUBSTR(DWORK,9,4))                                               
 POS1=15                                                                       
 DO WHILE POS1 < USEDLEN                                                       
   IF SUBSTR(DWORK,POS1+1,1) = '0'                                             
    THEN DO                                                                     
         CATNAME=SUBSTR(DWORK,POS1+2,44)                                       
         IF CATNAME ^= CATNAMET THEN                                           
          DO                                                                   
           CATNAMET = CATNAME                                                   
          END                                                                   
         POS1 = POS1 + 50                                                       
         END                                                                   
   DNAME = SUBSTR(DWORK,POS1+2,44)                                             
    POS1 = POS1 + 46                                                           
    CREDAT = C2X(SUBSTR(DWORK,POS1+8,4))                                       
    IF CREDAT = 'FFFFFFFF' ! CREDAT = '00000000' THEN ITERATE                   
    IF SUBSTR(CREDAT,7,2) = 0                                                   
      THEN ADDCENT = 1900000                                                   
      ELSE ADDCENT = 2000000                                                   
    CREDAY = INSERT('/',SUBSTR(CREDAT,1,5) + ADDCENT,4)                         
    IF DNAMET ^= DNAME THEN DO                                                 
     SAY DNAME CREDAY                                                           
     DNAMET=DNAME                                                               
    END                                                                         
    POS1 = POS1 + C2D(SUBSTR(DWORK,POS1,2))                                     
  END                                                                           
END                                                                             
END                                                                             
EXIT                                                                           
/** STANDARD REXX ERROR ROUTINE                                      */         
ERR:                                                                           
  SIGNAL OFF SYNTAX                                                             
  DELSTACK                                                                     
  SAY "ERROR ROUTINE OUTPUT STARTING"                                           
  SAY "   "                                                                     
  SAY RIGHT(SIGL,6) ">>>" SOURCELINE(SIGL)                                     
  SAY "   "                                                                     
  TRACE I                                                                       
  INTERPRET SOURCELINE(SIGL)                                                   
Back to top
View user's profile Send private message
Apeksha

New User


Joined: 21 May 2008
Posts: 37
Location: Mumbai

PostPosted: Fri Jun 13, 2008 12:13 pm
Reply with quote

Hi

I am trying to run this code but seems not working correctly... can you please help out? I am new to REXX

I didnt understand how this DWORK is getting calculated and what should be the expected value?

Thanks,
Apeksha.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10886
Location: italy

PostPosted: Fri Jun 13, 2008 12:24 pm
Reply with quote

does not work is a bit generic to deserve any consideration for help

certainly the script did not wash your dishes or mop the floor
so does not work applies to such tasks
the advice is hire a maid


dwork is built as a storage area to be passed to IGGCSI
Code:
WORKLEN = 4096                                                                 
DWORK = '00001000'X !! COPIES('00'X,WORKLEN-4)                                 

dwork is built as a storage areaof length 4096
initialized to 4 hex bites concatenated to 4092 bytes of hex zeroes

check the IGGCSI docs
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Fri Jun 13, 2008 6:25 pm
Reply with quote

And it worked before I posted it icon_biggrin.gif
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 Unable to interpret a hex value to De... COBOL Programming 4
No new posts Date format correction using dfsort DFSORT/ICETOOL 3
No new posts Sorting Date Field DFSORT/ICETOOL 4
No new posts CONVERT a given date from UTC TO BST CICS 0
No new posts Pull data using date difference betwe... DB2 6
Search our Forums:

Back to Top