Numeric functions perform mathematical operations on numerical data types or return numeric information.
Sybase IQ does not have the same constants or data type promotions as Adaptive Server Anywhere, with which it shares a common user interface. If you issue a SELECT statement without a FROM clause, the statement is passed through to Adaptive Server Anywhere. For the most consistent results, include the table name in the FROM clause whether you need it or not.
Consider creating a dummy table to use in such cases.
Table 5-8 lists numeric functions and their parameters.
Numeric function |
Parameters |
---|---|
ABS |
( numeric-expr ) |
ACOS |
( numeric-expr ) |
ASIN |
( numeric-expr ) |
ATAN |
( numeric-expr ) |
ATAN2 |
( numeric-expr1, numeric-expr2 ) |
CEIL |
( numeric-expr ) |
CEILING |
( numeric-expr ) |
COS |
( numeric-expr ) |
COT |
( numeric-expr ) |
DEGREES |
( numeric-expr ) |
EXP |
( numeric-expr ) |
FLOOR |
( numeric-expr ) |
LN |
( numeric-expr ) |
LOG |
( numeric-expr ) |
LOG10 |
( numeric-expr ) |
MOD |
( dividend, divisor ) |
PI |
( * ) |
POWER |
( numeric-expr1, numeric-expr2 ) |
RADIANS |
( numeric-expr ) |
RAND |
( [ integer-expr ] ) |
REMAINDER |
( numeric-expr, numeric-expr ) |
ROUND |
( numeric-expr, integer-expr ) |
SIGN |
( numeric-expr ) |
SIN |
( numeric-expr ) |
SQRT |
( numeric-expr ) |
SQUARE |
( numeric-expr ) |
TAN |
( numeric-expr ) |
“TRUNCATE” |
( numeric-expr, integer-expr ) |
TRUNCNUM |
( numeric-expression, integer-expression ) |
WIDTH_BUCKET |
( expression, min_value, max_value, num_buckets ) |