Page 1 of 2

GDG delete

PostPosted: Sat Nov 16, 2013 4:00 pm
by mohbaig
HI, i used the below code to delete the entire GDG associations. But GDG versions are just uncatalogued,but not deleted.They are still existing on the volume.

advice.

// EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
DELETE MATE04.TEST.GDGBASE GDG -
PURGE -
FORCE
/*

Re: GDG delete

PostPosted: Sat Nov 16, 2013 6:17 pm
by BillyBoyo
Consult the manual. Establish why it didn't do what you expect. Set up a GDG and a couple of generations to test the delete with. Correct your control cards. Repeat until successful in achieving what you set out to do.

If you do become bogged down in this, post back what you were trying, the control cards you used, and the output. Someone will be here to help.

Re: GDG delete

PostPosted: Sat Nov 16, 2013 7:08 pm
by Robert Sample
Hint: your problem is not with the delete but with the IDCAMS DEFINE statement.

Re: GDG delete

PostPosted: Sat Nov 16, 2013 7:24 pm
by mohbaig
The below code is used to define the GDG base.

// EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
DEFINE GDG(NAME(MATE04.TEST.GDGBASE) -
LIMIT(7) -
NOEMPTY -
SCRATCH )
/*

Re: GDG delete

PostPosted: Sat Nov 16, 2013 9:04 pm
by Robert Sample
Are the generations on tape or disk?

Re: GDG delete

PostPosted: Sat Nov 16, 2013 9:20 pm
by mohbaig
They are on disk Robert.

Re: GDG delete

PostPosted: Sun Nov 17, 2013 7:00 am
by c62ap90
DELETE MATE04.TEST.GDGBASE.* {this deletes all GDG's and keeps the base}
DELETE MATE04.TEST.GDGBASE GDG {this deletes the GDG base. You must do above first for this to work}

Re: GDG delete

PostPosted: Sun Nov 17, 2013 4:49 pm
by mohbaig
DELETE MATE04.TEST.GDGBASE.* is not deleting any of the GDG versions.
and
DELETE MATE04.TEST.GDGBASE GDG is just deleting the GDG base and uncataloguing the versions.

SO, manually deleting the versions by using line command D from 3.4/DSNAME level and Volume after deleting the GDG base.

Re: GDG delete

PostPosted: Sun Nov 17, 2013 7:40 pm
by Robert Sample
1. Terminology is critical in IT, where similar terms may mean very different things. A GDG has both a version and a generation -- but they are handled very differently. You need to figure out whether you are talking about generations or versions.

2. Your last post
DELETE MATE04.TEST.GDGBASE.* is not deleting any of the GDG versions.
and
DELETE MATE04.TEST.GDGBASE GDG is just deleting the GDG base and uncataloguing the versions.

SO, manually deleting the versions by using line command D from 3.4/DSNAME level and Volume after deleting the GDG base.
indicates that you may not have a GDG since the DELETE commands WILL remove the generations, or you do not understand what is going on, or you are not tellilng us everything.

For further assistance, post the IDCAMS output (using the CODE tag) from these commands:
  LISTCAT LEVEL(MATE04.TEST.GDGBASE) ALL
  DELETE MATE04.TEST.GDGBASE.*
  LISTCAT LEVEL(MATE04.TEST.GDGBASE) ALL
  DELETE MATE04.TEST.GDGBASE GDG
  LISTCAT LEVEL(MATE04.TEST.GDGBASE) ALL
Post the actual output with message numbers and everything -- if you do not post the actual output of these commands, this topic will be locked.

Re: GDG delete

PostPosted: Sun Nov 17, 2013 8:12 pm
by mohbaig
1                         J E S 2  J O B  L O G  --  S Y S T E M  S Y S 1  --  N
0
 08.38.22 JOB05834 ---- SUNDAY,    17 NOV 2013 ----
 08.38.22 JOB05834  IRR010I  USERID MATE04   IS ASSIGNED TO THIS JOB.
 08.38.22 JOB05834  ICH70001I MATE04   LAST ACCESS AT 08:37:28 ON SUNDAY, NOVEMB
 08.38.22 JOB05834  $HASP373 MATE04D  STARTED - INIT 5    - CLASS A - SYS SYS1
 08.38.22 JOB05834  IEF403I MATE04D - STARTED - TIME=08.38.22
 08.38.22 JOB05834  IEF404I MATE04D - ENDED - TIME=08.38.22
 08.38.22 JOB05834  $HASP395 MATE04D  ENDED
0------ JES2 JOB STATISTICS ------
-  17 NOV 2013 JOB EXECUTION DATE
-           11 CARDS READ
-           61 SYSOUT PRINT RECORDS
-            0 SYSOUT PUNCH RECORDS
-            3 SYSOUT SPOOL KBYTES
-         0.00 MINUTES EXECUTION TIME
         1 //MATE04D  JOB MSGLEVEL=(1,1),NOTIFY=&SYSUID
           IEFC653I SUBSTITUTION JCL - MSGLEVEL=(1,1),NOTIFY=MATE04
         2 //         EXEC PGM=IDCAMS
         3 //SYSPRINT DD SYSOUT=*
         4 //SYSIN    DD *
         5 //SYSIN     DD *               GENERATED STATEMENT
 ICH70001I MATE04   LAST ACCESS AT 08:37:28 ON SUNDAY, NOVEMBER 17, 2013
 IEF236I ALLOC. FOR MATE04D
 IEF237I JES2 ALLOCATED TO SYSPRINT
 IEF237I JES2 ALLOCATED TO SYSIN
 IEF237I JES2 ALLOCATED TO SYSIN
 IEF142I MATE04D - STEP WAS EXECUTED - COND CODE 0012
 IEF285I   MATE04.MATE04D.JOB05834.D0000103.?           SYSOUT
 IEF285I   MATE04.MATE04D.JOB05834.D0000101.?           SYSIN
 IEF285I   MATE04.MATE04D.JOB05834.D0000102.?           SYSIN
 IEF373I STEP/        /START 2013321.0838
 IEF374I STEP/        /STOP  2013321.0838 CPU    0MIN 00.08SEC SRB    0MIN 00.01
 IEF375I  JOB/MATE04D /START 2013321.0838
 IEF376I  JOB/MATE04D /STOP  2013321.0838 CPU    0MIN 00.08SEC SRB    0MIN 00.01
1IDCAMS  SYSTEM SERVICES                                           TIME: 08:38:2
0
   LISTCAT LEVEL(MATE04.TEST.GDGBASE) ALL
0IDC3004I FUNCTION TERMINATED. INSUFFICIENT MAIN STORAGE
0IDC3003I FUNCTION TERMINATED. CONDITION CODE IS 12
0
   DELETE MATE04.TEST.GDGBASE.*
0IDC3012I ENTRY MATE04.TEST.GDGBASE. NOT FOUND
 IDC3007I ** VSAM CATALOG RETURN CODE IS 8
0IDC0001I FUNCTION COMPLETED, HIGHEST CONDITION CODE WAS 8
0
   LISTCAT LEVEL(MATE04.TEST.GDGBASE) ALL
0IDC3004I FUNCTION TERMINATED. INSUFFICIENT MAIN STORAGE
0IDC3003I FUNCTION TERMINATED. CONDITION CODE IS 12
0
   DELETE MATE04.TEST.GDGBASE GDG
0IDC3012I ENTRY MATE04.TEST.GDGBASE NOT FOUND
 IDC3009I ** VSAM CATALOG RETURN CODE IS 8 - REASON CODE IS IGG0CLA3-42
 IDC0551I ** ENTRY MATE04.TEST.GDGBASE NOT DELETED
0IDC0001I FUNCTION COMPLETED, HIGHEST CONDITION CODE WAS 8
0
   LISTCAT LEVEL(MATE04.TEST.GDGBASE) ALL
0IDC3004I FUNCTION TERMINATED. INSUFFICIENT MAIN STORAGE
0IDC3003I FUNCTION TERMINATED. CONDITION CODE IS 12
0
0IDC0002I IDCAMS PROCESSING COMPLETE. MAXIMUM CONDITION CODE WAS 12