Arithmetic Operators

These arithmetic operators are available in Sybase IQ.

Arithmetic operators

Operator

Description

expression + expression

Addition. If either expression is the NULL value, the result is the NULL value.

expression - expression

Subtraction. If either expression is the NULL value, the result is the NULL value.

- expression

Negation. If the expression is the NULL value, the result is the NULL value.

expression * expression

Multiplication. If either expression is the NULL value, the result is the NULL value.

expression / expression

Division. If either expression is the NULL value or if the second expression is 0, the result is the NULL value.

expression % expression

Modulo finds the integer remainder after a division involving two whole numbers. For example, 21 % 11 = 10 because 21 divided by 11 equals 1 with a remainder of 10.