To Specify Dataset Allocation Using Environment Variables

To configure datasets, you can specify the full path for each dataset accessed by Enterprise Server. However this is cumbersome and can make it difficult to move between test and production environments that have different directory structures.

To reduce the effort required when the system uses large numbers of data files, you can set environment variables to define the datasets that an Enterprise Server instance uses:

  1. From the Enterprise Server Administration page, click the Edit button that corresponds to the Enterprise Server instance to configure.
  2. Select the Server > Properties > General tabs.
  3. In the Configuration Information text box, type: [ES-Environment]
  4. Configure the datasets to use with the ENVIRONMENTVAR=path syntax where:
    • ENVIRONMENTVAR is the name of the environment variable you are creating
    • path is the full path, including the drive letter, to the dataset.

    You can create as many environment variables as you need to cover all of the paths you want to specify.

  5. When you have defined the datasets, click OK. The settings are applied to the Enterprise Server instance.
  6. In the catalog, when allocating datasets using the %PCDSN option to specify a physical file, you can substitute an environment variable that you defined to represent the path to the file. Prefix environment variable names with a dollar sign ($): $ENVIRONMENTVAR