Previous Topic: Source File Names

Next Topic: More Information

High Level Language Naming Restrictions

Different CA 2E HLLs impose different restrictions on the names they allow and, therefore, to the names you can give to files, formats, and fields. CA 2E also requires that you reserve the first two characters in field names for a format prefix.

Other restrictions depend on your target HLL. For example, restrictions on length are generally more severe in RPG than in COBOL. However, RPG lets you use some non-alphabetic characters, such as #, &, or @, in names, that COBOL does not allow.

The HLL name validation model value, YHLLVNM, lets you specify that names must satisfy RPG restrictions, COBOL restrictions, or both. If you are generating a database for use with both COBOL and RPG programs, use names that satisfy both sets of restrictions.

The default for the model value YHLLGEN is *RPGCBL. The CA 2E convention using *RPGCBL produces names of 8 or less characters that would be valid names on most platforms.

The following table describes YHLLVNM and HLL name restrictions:

Restricted

DDS

RPG

COBOL

#RPG

#RPGCBL

#CBL

File Name Max Length

10

8

30

8

8

10

Format Name Max Length

10

8

30

8

8

10

Field Name Max Length

10

8

30

2 + 4*

2 + 4*

2 + 4*

Allow #, @, etc.

Yes

Yes

No

Yes

No

No

*Where 2 is the length of the prefix and 4 or 8 is the remainder of the name.

When you create a new model, you set the initial value for the YHLLVNM model value. The default for this model value is the same as the value set for the HLLGEN parameter.

You can change the model value for the YHLLVNM using the Change Model Value (YCHGMDLVAL) command.

Note: If your HLL is COBOL, the first five characters of the name must be unique.

If you have a model originally implemented with model value YHLLVNM set to RPG and you want to regenerate it in COBOL, you must convert the implementation names so that they satisfy COBOL restrictions.

For more information about: