pTAL Reference Manual (H06.03+)

Expressions
HP pTAL Reference Manual523746-005
5-18
Relational Operators
NOT, OR, and AND Operators and Condition Codes
If the root operator in the conditional expression of an IF statement is a relational
operator (<, =, >, <=, <>, >=, '<', '=', '>', '<=', '<>', '>='), pTAL sets the condition code
according to the result of the comparison.
Relational operators that test the condition code (for example, IF < THEN...) do not set
the condition code.
NOT, OR, and AND operators set the condition code indicator as described in
Section 13, Hardware Indicators.
Relational Operators
Signed Relational Operators on page 5-18
Unsigned Relational Operators on page 5-19
Signed Relational Operators
Signed relational operators perform signed comparison of two operands and return a
true or false state.
Table 5-14. Signed Relational Operators
Operator Meaning Operand Type
*
Result
< Signed less than Any data type True/False
= Signed equal to Any data type True/False
> Signed greater than Any data type True/False
<= Signed less than or equal to Any data type True/False
>= Signed greater than or equal to Any data type True/False
<> Signed not equal to Any data type True/False
*
The data type of the operands must match except as noted in Data Types of Expressions
on page 5-2.