Copying your JCL library

Your JCL library contains a $$JCLCPY sample member that you can use to copy your JCL library to a new library. While you can use other methods to copy the library, the $$JCLCPY job performs the following functions to lessen the changes you need to make in the copy:

  • Allocates the new data set if it does not already exist.

  • Copies all members from the original JCL data set to the new one.

  • Changes the JCL in the copied members to reference the new JCL data set name instead of the original JCL data set name.

Use the following procedure to make a copy of your JCL library.

To make a copy

  1. (optionally) Edit the $$JCLCPY member to specify the name of a new JCL data set.

    The output data set name is specified as &DVOLIB..BKUP in the sample. Change the output data set name to a valid name for the new JCL library.

    //IN       DD *           
      BMIRXCL '&DVOLIB' +     
              '&DVOLIB..BKUP'

    If you do not change the name, the JCL library will be named the same as your original library with the BKUP low-level qualifier added to it. For example, if the original data set name is MY.INSTALL.JCL, the copy would be named MY.INSTALL.JCL.BKUP.

    Important

    Do not change the input data set name (&DVOLIB) or the copy will not work properly.

  2. Run the $$JCLCPY job.

    The new library is created.

Where to go from here

Continue to Modifying INCLUDE members.

Was this page helpful? Yes No Submitting... Thank you

Comments