FirebirdSQL logo

LN()

Natural logarithm

Result type

DOUBLE PRECISION

Syntax
LN (number)
Table 1. LN Function Parameter
Parameter Description

number

An expression of a numeric type

An error is raised if the argument is negative or 0.

LOG()

Logarithm with variable base

Result type

DOUBLE PRECISION

Syntax
LOG (x, y)
Table 1. LOG Function Parameters
Parameter Description

x

Base.An expression of a numeric type

y

An expression of a numeric type

Returns the x-based logarithm of y.

  • If either argument is 0 or below, an error is raised.

  • If both arguments are 1, NaN is returned.

  • If x = 1 and y < 1, -INF is returned.

  • If x = 1 and y > 1, INF is returned.