Previous Topic: NCL Reference, Type Checking, and Data Behavior

Next Topic: INTEGER Type

BOOLEAN Type

The BOOLEAN type is used to represent a value of true or false only.

External Form - Input

The local character strings TRUE and FALSE (not case sensitive) are accepted, while the digit 0 is interpreted as false, and the digit 1 is true.

External Form - Output

The digit 0 (false) or 1 (true) is always returned.

Local Form and Behavior

Internally, Mapping Services stores a value of X'00' for false, and X'01' for true (and accepts any value other than X'00' as true).

For an input operation, where the component is variable length, its length is always set to 1. Where the component length is fixed and is greater than 1, the value occupies the first byte only (that is, it is left-aligned) and the remainder of the component's data is set to zeros.

For an output operation, where the component is located and has a length greater than 1, only the first byte is inspected as the value.