Just as for the creation of generations, deleting a generation must leave no gaps in the sequence of absolute generation numbers. Thus, starting from the generation to be deleted (the POS operand in the ERASE macro; DELETE operand in the DELETE-FILE-GENERATION command), only all older or all newer generations can be deleted.
If the current base generation for relative generation numbers is deleted, the generation specified in the ERASE macro or DELETE-FILE-GENERATION command becomes the new base generation.
The fields in the group entry are updated accordingly (BASE-NUM, FIRST-GEN, LAST-GEN).
File generation groups can be deleted by specifying the group name in the ERASE macro or DELETE-FILE-GROUP command. The group entry and all related file generations which are currently cataloged are erased.
In the ERASE macro (VERSION=1 / 2 / 3), the user may also specify the selection operand TYPE=FGG or wildcards in the file name in order to erase several file generation groups at the same time.
The user may also specify wildcards in the file name in the DELETE-FILE-GROUP command in order to erase several file generation groups at the same time.
Example: deleting generations
Initial situation: GROUP1 consists of generations 6 to 9, BASE-NUM = 7