Operators
228
Join operators
The Transact-SQL outer join operators *= and =* are supported in Adaptive
Server Anywhere, in addition to the SQL/92 join syntax that uses a table
expression in the FROM clause.
♦
Modulo The % operator can be used in Adaptive Server Anywhere
only if the PERCENT_AS_COMMENT
option is set to OFF. The
default value is ON.
♦
String concatenation When using the + concatenation operator in
Adaptive Server Anywhere, you should explicitly set the operands to
strings rather than relying on implicit data conversion. For example, the
following query returns the integer value 579
SELECT 123 + 456
whereas the following query returns the character string 123456
SELECT ’123’ + ’456’
You can use the CAST or CONVERT function to explicitly convert data
types.
The || concatenation operator is not supported by Adaptive Server
Enterprise.
Operator precedence
The precedence of operators in expressions is as follows. The operators at the
top of the list are evaluated before those at the bottom of the list.
1 unary operators
2’.’ (the Java reference operator)
3’&’, ’|’, ’^’, ’~’
4’*’, ’/’, ’%’
5’+’, ’-’
6’||’
7 not
8 and
9 or
Compatibility