| Function | Type | What it does |
|---|---|---|
abs | Scalar | Returns the absolute value of a number. |
acos | Scalar | Returns the inverse cosine of a number. |
acosh | Scalar | Returns the inverse hyperbolic cosine of a number. |
asin | Scalar | Returns the inverse sine of a number. |
asinh | Scalar | Returns the inverse hyperbolic sine of a number. |
atan | Scalar | Returns the inverse tangent of a number. |
atan2 | Scalar | Returns the angle of the point (x, y) measured from the positive x axis. |
atanh | Scalar | Returns the inverse hyperbolic tangent of a number. |
cbrt | Scalar | Returns the cube root of a number. |
ceil | Scalar | Rounds a number upward to an integral value. |
ceiling | Scalar | Rounds a number upward to an integral value. |
conv | Scalar | Converts an integer represented as text from one base to another. |
cos | Scalar | Returns the cosine of an angle. |
cosec | Scalar | Returns the cosecant of an angle. |
cosh | Scalar | Returns the hyperbolic cosine of a number. |
cot | Scalar | Returns the cotangent of an angle. |
csc | Scalar | Returns the cosecant of an angle. |
degrees | Scalar | Converts radians to degrees. |
exp | Scalar | Returns e raised to the power of a number. |
factorial | Scalar | Returns the factorial of an integer. |
floor | Scalar | Rounds a number downward to an integral value. |
hex | Scalar | Returns the hexadecimal representation of a number, string or binary value. |
isnan | Scalar | Tests whether a numeric value is NaN. |
ln | Scalar | Returns the natural logarithm of a number. |
log | Scalar | Returns a logarithm in the specified base. |
log10 | Scalar | Returns the base-ten logarithm of a number. |
log1p | Scalar | Returns the natural logarithm of one plus the input. |
log2 | Scalar | Returns the base-two logarithm of a number. |
mod | Scalar | Returns the remainder of division. |
pi | Scalar | Returns a floating-point approximation of pi. |
pmod | Scalar | Returns the remainder adjusted using ((value % divisor) + divisor) % divisor. |
pow | Scalar | Raises a base to an exponent. |
power | Scalar | Raises a base to an exponent. |
radians | Scalar | Converts degrees to radians. |
rand | Scalar | Returns a pseudorandom number whose type depends on the source dialect. |
random | Scalar | Returns a pseudorandom number whose type depends on the source dialect. |
rint | Scalar | Rounds a number to the nearest integer, resolving halfway values to the even integer. |
round | Scalar | Rounds a number to the requested decimal position, resolving halfway values away from zero. |
sec | Scalar | Returns the secant of an angle. |
seq1 | Scalar | Produces a sequence of BIGINT values for each query, wrapping at the 8-bit boundary according to the sign option. |
seq2 | Scalar | Produces a sequence of BIGINT values for each query, wrapping at the 16-bit boundary according to the sign option. |
seq4 | Scalar | Produces a sequence of BIGINT values for each query, wrapping at the 32-bit boundary according to the sign option. |
seq8 | Scalar | Produces a sequence of BIGINT values for each query, wrapping at the 64-bit boundary according to the sign option. |
sign | Scalar | Returns the sign of a number or interval. |
signum | Scalar | Returns the sign of a number or interval. |
sin | Scalar | Returns the sine of an angle. |
sinh | Scalar | Returns the hyperbolic sine of a number. |
sqrt | Scalar | Returns the square root of a number. |
tan | Scalar | Returns the tangent of an angle. |
tanh | Scalar | Returns the hyperbolic tangent of a number. |
try_divide | Scalar | Divides two numbers, returning NULL for a zero divisor. |
try_multiply | Scalar | Multiplies two numbers, returning NULL on integer or decimal overflow. |
width_bucket | Scalar | Returns the bucket containing a value within an equal-width range. |
Math functions
Arithmetic, rounding, logarithmic, trigonometric and other numeric functions.
Arithmetic, rounding, logarithmic, trigonometric and other numeric functions.
Last modified on October 15, 2026