Multiple choice technology mainframe

Job have 3 steps in 1) Step01 creating New GDG file(+), 2) Step02 Delete file(+), 3) Step03 create new GDG file with same file name JCL has been executed twice What is the version for that file?

  1. gdg(0)

  2. gdg(+3)

  3. gdg(+4)

  4. gdg(+2)

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

When the JCL runs twice, each execution creates 2 new GDG versions: Run 1 creates (+1) and (+2), Run 2 creates (+3) and (+4). After deleting the intermediate version, the final version number from the second run's create step is +4. GDG versions increment sequentially with each generation.

AI explanation

To determine the version of the file after executing the given JCL steps, let's analyze each step:

1) Step01: Creating a new GDG file with the same file name.

  • This step will create a new version of the GDG file with a higher version number.

2) Step02: Deleting the file.

  • This step will remove the current version of the GDG file.

3) Step03: Creating a new GDG file with the same file name.

  • This step will create a new version of the GDG file with a higher version number.

Since the JCL has been executed twice, the final version of the GDG file will be increased by 2 (one for each execution of the JCL).

Given that the initial GDG file version is 0, the final version of the file will be gdg(+4) (0 + 2 + 2 = 4).

Therefore, the correct answer is C) gdg(+4).