PRESERVECASE

Ensures that COBOL items declared in the current program retain their case and are not converted to uppercase as is usual in COBOL. This enables the items to be found from outside the program.

Syntax:

>>-.----.--PRESERVECASE---------><
   +-NO-+

Parameters:

None

Properties:

Default:

PRESERVECASE

Phase: Syntax check
$SET: Any

Comments:

PRESERVECASE preserves the case of those items for which the COBOL name determines a name that is visible externally (such as PROPERTY names specified without the AS clause). The exact case of the COBOL name used in the declaration is the case used for the external name. References to the item from within the same COBOL program can still use any case combination.

The directive also preserves the case of data-names in output from the XML GENERATE statement.

Example:

$set preservecase
01 Fred property binary-long.
*> Sets up a property with external name "Fred"

procedure division.
    Move 999 to fred
*> fred is a normal COBOL data name and can therefore be accessed using any case