Generation Data Group

from Wikipedia, the free encyclopedia

Generation Data Group ( GDG ) is a special type of files in mainframe operating systems of IBM - z / OS series. The actual GDG is a description of how many generations of a file should be kept and how old the oldest generation must be at least before it is deleted.

Whenever a new generation is created, the system checks whether one or more obsolete generations should be deleted and, if necessary, the deletion is carried out.

The purpose of GDGs lies in the automatic historization, whereby the name is given neutrally for the JCL , the command language. The GDG name appears as the DSN together with the history number, whereby

  • (0) is the most recent, current version
  • (-1), (-2), ... are the next older generations
  • (+1) creates a new generation ( see DD )

Another possibility of using GDGs is the possibility of addressing all generations simultaneously within a JCL without having to know the number of generations currently available. For this purpose, the brackets and generation number are omitted in the JCL when specifying the dataset .

example

Creation of a standard GDG for five backup copies, each at least 35 days old:

//STEP1 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
  DEFINE GDG (NAME('DB2.FULLCOPY.DSNDB04.TSTEST') LIMIT(5) SCRATCH FOR(35))
/*

Deleting a standard GDG:

//STEP3 EXEC PGM=IDCAMS                  
//SYSPRINT DD SYSOUT=*                   
//SYSIN DD *                             
DELETE DB2.FULLCOPY.DSNDB04.TSTEST GDG FORCE  
/*

Web links