IF [ HP TRANSACT Quick Reference Guide ] MPE/iX 5.0 Documentation
HP TRANSACT Quick Reference Guide
IF
IF condition-clause THEN statement [ELSE statement];
CONDITION CLAUSE
test-variable relational-operator value[,value...][{AND|OR} ...]
TEST VARIABLES
(item-name[(subscript)])
arithmetic-expression
EXCLAMATION - Status of automatic null response
FIELD - Status of the FIELD option
INPUT - Last value input to INPUT
PRINT - Status of PRINT or TPRINT option
REPEAT - Status of REPEAT option
SORT - Status of SORT option
STATUS - Value of STATUS register
RELATIONAL OPERATORS
=
<>
<
<=
>
>=
When test variable is (item-name[(subscript)]) and relational operator is
"=" or "<>", value can be:
NUMERIC
ALPHABETIC
ALPHABETIC-LOWER
ALPHABETIC-UPPER
Example
IF (QTY)>(ONHAND) THEN DISPLAY "Too many ordered!";
MPE/iX 5.0 Documentation