LN Function [Numeric]

Returns the natural logarithm of the specified expression.

Syntax

LNnumeric-expression )

Parameters

Parameter

Description

expression

Is a column, variable, or expression with a data type that is either exact numeric, approximate numeric, money, or any type that can be implicitly converted to one of these types. For other data types, the LN function generates an error. The return value is of DOUBLE data type.

Usage

LN takes one argument. For example, LN (20) returns 2.995732.

The LN function is an alias of the LOG function.

Standards and Compatibility

  • SQL—Vendor extension to ISO/ANSI SQL grammar.

  • Sybase—Not supported by Adaptive Server Enterprise. Use the LOG function instead.

Related reference
LOG Function [Numeric]
LOG10 Function [Numeric]