SQL/MX 2.x Reference Manual (H06.04+)

SQL/MX Functions and Expressions
HP NonStop SQL/MX Reference Manual540440-003
9-84
MOD Function
MOD Function
The MOD function returns the remainder (modulus) of an integer value expression
divided by an integer value expression.
MOD is an SQL/MX extension.
integer-expression-1
is an SQL numeric value expression of data type SMALLINT, INTEGER, or
LARGEINT that specifies the value for the dividend argument of the MOD function.
integer-expression-2
is an SQL numeric value expression of data type SMALLINT, INTEGER, or
LARGEINT that specifies the value for the divisor argument of the MOD function.
The divisor argument cannot be zero.
See Numeric Value Expressions on page 6-48.
Examples of MOD
This function returns the value 2 as the remainder or modulus:
MOD (11,3)
MOD (integer-expression-1,integer-expression-2)