Arbortext Command Language > Using the Arbortext Command Language > Relational
  
Relational
It is important to note that the order in which items appear in this table are arbitrary. All operators have equal precedence to ACL.
Relational table
<
$x < 5 returns a value of 1 if the value of $x is less than 5; otherwise returns 0 (zero).
>
$x > $y returns a value of 1 if the value of $x is greater than the value of $y; otherwise returns 0 (zero).
<=
$x <= $q returns a value of 1 if the value of x is less than or equal to the value of $q; otherwise returns 0 (zero).
>=
$x >= 3 returns a value of 1 if the value of $x is greater than or equal to 3; otherwise returns 0 (zero).
==
$x == 5 returns a value of 1 if the value of $x is equal to 5; otherwise returns 0 (zero).
!=
$s != "string" returns a value of 1 if the value of $s is not “string”; otherwise returns 0 (zero).
The relational operators (<, >, <=, >=, ==, and !=) use arithmetic comparisons if both operands are numerals; otherwise, string comparisons are used. White space may delimit operators, but it is not required.
The following operators are numeric and require numeric operands:
+, -, *, /, &, ^, |, <<, >>, %, ~, ++, and ––
Related Topics
Functions as expressions and commands
Using expressions
Logical expressions
Operands