Submitting JCL with dynamic variable substitution

Learn how to use Menu Manager and the JCL substitution mechanism to submit JCL with dynamic variable substitution.

If you have multiple programs of the same type, for example, COBOL with CICS® and Db2®, and these programs use the same JCL to compile and link-edit them, you can create an action that compiles each program by using the same JCL. This action eliminates the need to create a separate JCL file for each of these programs and then modify that JCL each time a different program must be compiled. You need to edit the JCL only once to mark the parameters that must be overridden for each compilation.

You can dynamically link resources to commands and start those commands with different parameters. You can use these abilities to do the following tasks:

  • Submit different JCL for the same resource, each time with different parameters, without modifying the source JCL files. The resource in this case is a different entity from the JCL that is to be submitted.
  • Submit the JCL that is itself the resource that is being acted on. You can submit the same JCL different times with different parameters without modifying the original JCL source.
  • Provide JCL that multiple users can share; each user does not need modified versions of the JCL files.

This tutorial describes how to use these capabilities.

Learning objectives

Using this tutorial, you learn how to do the following tasks:
  • Prepare the JCL for dynamic variable substitution
  • Create a menu action with default override values for identified parameters
  • Test the new action

Time required

This tutorial takes approximately 60 minutes to finish. If you explore other concepts that are related to this tutorial, it can take longer to complete.

Prerequisites

Before you complete the lessons that are described in this tutorial, you must do the following steps:
  1. Connect to a remote system.
  2. Create a z/OS project and MVS subproject in the z/OS Projects view.
  3. Add data sets to the subproject that you can submit for compiling and link-editing. You use these data sets to test the new action.