Curriculum
Course: SQL
Login

Curriculum

SQL

SQL References

0/80

MySQL Functions

0/139

SQL Server Functions

0/84

SQL Quick Ref

0/1
Text lesson

LN

Example

Provide the logarithm base e of 2.

SELECT LN(2); 

Definition and Usage

The LN() function computes the natural logarithm of a given number.

Note: Also refer to the LOG() and EXP() functions for related operations.

Syntax

LN(number)

Parameter Values

Parameter

Description

number

Mandatory: A numerical value that must exceed 0.

Technical Details

Works in: From MySQL 4.0

More Examples

Example

Give the logarithm base e of 1.

SELECT LN(1);