Skip to main content
Scalar function
Returns NULL when an argument is NULL.

Syntax

Scalar

Arguments

Returns

  • Type: DOUBLE; FLOAT when the input is evaluated as FLOAT
  • Possible values: Nonnegative values for input at least 1; NaN below 1.
  • NULL behavior: Returns NULL when an argument is NULL.

Properties

  • Approximation bound: No fixed maximum error is guaranteed.

Usage notes

  • Numeric inputs are normally converted to DOUBLE for calculation. An input evaluated as FLOAT keeps FLOAT precision.
  • INTEGER and INT mean the same type; STRING means VARCHAR text. NULL can be used with a supported type. Cast NULL explicitly when its type would otherwise be unclear.
  • Exact result: Floating-point computation can round the mathematical result.

Examples

Value and NULL input

A nonzero input

The result is rounded to six decimal places for display.

Limitations

  • Input below 1 produces NaN rather than NULL.
  • Query tools may report DOUBLE even when the result is FLOAT. The reported type does not increase the result’s precision.
Last modified on October 15, 2026