ENFORM Reference Manual

Logical Expressions
ENFORM Language Elements
3–24 058057 Tandem Computers Incorporated
Scale Factor of the Result The scale of the result is determined by the number of digits after the decimal point.
In an arithmetic expression, the result has the same number of digits after the decimal
point as the field or variable in the expression with the greatest precision. This could
result in loss of significant digits if too great a precision is used for the field or variable.
The resulting scale factor can be controlled by assigning the result of the arithmetic
expression to a user variable. (User variables are explained later in this section.) The
precision of the user variable can be specified by an INTERNAL clause within the
DECLARE statement that defines the user variable. The maximum number of digits
allowed is 18. All calculations with ENFORM are performed with QUAD arithmetic.
Logical Expressions Logical expressions evaluate to a truth value—either true or false based on a condition
specified within the expression. Both the conditions that can be specified and the
conditional operators are shown in Table 3-4.
Table 3-4. Conditional Operators
Condition Keyword Abbreviation Symbol
Equal EQUAL
IS
EQ =
Not equal NE < >
Greater than GREATER [THAN] GT >
Greater than or equal to GE >=
Less than LESS [THAN] LT <
Less than or equal to LE <=
ENFORM provides two other conditional operators: BEGINS WITH and CONTAINS.
The three symbols ‘]’ are synonymous with BEGINS WITH and the three symbols ‘>‘
are synonymous with CONTAINS.