Symbolic parameters used with COBOL generation
- Certain build descriptor options
- Build scripts for iSeries® and z/OS®
- Runtime JCL or CL templates
- Link edit parts
- Bind control parts
- Predefined symbolic parameters that are set automatically
- These are substitution values for predefined symbols which are automatically set at generation, based on the part that is being generated or other information available during the generation process. The value for these symbols cannot be changed.
- Predefined symbolic parameters that can be set by the user
- There are certain predefined symbols that are used in the build scripts and templates, and you can set these at generation time. In addition, there are a few predefined symbols that you can set that affect the generated COBOL code. These symbolic parameters are used for information that is required for most customers, but that generally has a unique value for each customer. For example, the name of the data set that contains the COBOL compiler generally varies for each customer. For information about these types of parameters, see Predefined symbolic parameters that can be set by the user.
- User-defined symbolic parameters
- You might need to customize any of the following for your target
runtime environment:
- EGL-provided build scripts
- EGL-provided runtime JCL templates for z/OS® or runtime CL templates for iSeries®
- Bind control part to be used as a template for binding packages
- Link edit part to be used as a template
Both predefined and user-defined symbolic parameters are available as substitution variables in the build scripts used to prepare COBOL output. At COBOL build time, EGL passes all symbolic parameters to the build server. The passed values provide the values for build-script substitution variables of the same name, overriding the default values (if any) for those substitution variables. For details, see Modifying EGL build scripts for z/OS, and the EGL Server Guide for IBM® i.
You can specify the values for some predefined symbolic parameters. You can also define your own symbolic parameters, in addition to the predefined symbolic parameters, and for each such parameter you define, you assign a value. For example, the MYDIR symbolic parameter might contain the name of a directory. You cannot define the same symbolic parameter (like MYDIR) twice in the same build descriptor.
If the build descriptor you are using for generation uses the nextBuildDescriptor option to chain multiple build descriptors, and you define the same-named symbolic parameter in multiple build descriptors that are chained together, the value in use at generation time is determined by the precedence rules described in Build Descriptor part. The value assigned to the MYDIR symbolic parameter in the master build descriptor, for example, takes precedence over the value assigned to MYDIR in any other build descriptor.
Setting a language code page for your zSeries® COBOL environment
You can use EGL build descriptor symbolic parameters to set your language code page for the zSeries®.
In addition to the STRING and UNICODE data types that you can define in EGL, the language has internal literals defined as STRING. All of these STRING and UNICODE values are implemented in COBOL as PIC N, with the USAGE NATIONAL qualifier. In order for the COBOL compiler to correctly translate these PIC N values to Unicode values, it must know the codepage to use for the transformation. If your system programmers have not configured the CODEPAGE option for the COBOL compiler, or if the wrong page is specified, you may need to set the correct value yourself.
COBLISTPARMS LIST,NOOPT,CODEPAGE(1147)Refer to your COBOL manuals for the correct value for the CODEPAGE parameter. The following table contains a partial list:
| Value | Language |
|---|---|
| 420 | Arabic |
| 274 | Belgium (old) |
| 275 | Brazilian Portugese |
| 935 | Chinese (Simplified) |
| 1371, 937 | Chinese (Traditional) |
| 277 | Danish |
| 437 | English (Australian) |
| 1146, 285 | English (UK) |
| 1140, 437 | English (US) |
| 278 | Finnish |
| 1147, 297 | French |
| 273 | German |
| 875 | Greek |
| 424, 803 | Hebrew |
| 1149, 871 | Icelandic |
| 1144, 280 | Italian |
| 1390, 290, 930, 939 | Japanese |
| 1364, 933 | Korean |
| 1153, 870, 1148, 500 | Latin |
| 277 | Norwegian |
| 1156 | Russian (Baltic) |
| 1025, 1158 | Russian (Cyrillic) |
| 1122, 1157 | Russian (Estonian) |
| 1112 | Russian (Latvian) |
| 1112 | Russian (Lithuanian) |
| 1123, 1158 | Russian (Ukranian) |
| 1145, 284 | Spanish |
| 278 | Swedish |
| 838 | Thai |
| 1026 or 1155 | Turkish |
Examples
You can use symbolic parameters in the values for the genDirectory and the destDirectory build descriptor options, in build scripts, in templates, or in the link edit or bind control parts.
%EZEGTIME%You can also use more than one symbolic parameter to assign a value. For example, the following symbols represent date and time, separated by a space:
%EZEGDATE% %EZEGTIME%
For example, if genDirectory is set to C:\MyProject\%EZEENV%,
and the system build descriptor option is
set to ZOSCICS, then generation output will be written to C:\MyProject\ZOSCICS.
&EZEGDATE.//EZESRC DD DSN=&MYHLQ..;&SYSTEM..EZESRC;,DISP=SHRIf
you set the system build descriptor option
to ZOSCICS and set the MYHQL user-defined symbolic parameter to the
value MYQUAL, then the resulting line in the build script is the following://EZESRC DD DSN=MYQUAL.ZOSCICS.EZESRC,DISP=SHR