LN()
This page is part of MariaDB's Documentation.
The parent of this page is: Functions for MariaDB Xpand
Topics on this page:
Overview
Returns the natural logarithm of the argument.
USAGE
LN(number)
Argument Name | Description |
---|---|
| The number to measure |
DETAILS
LN()
is a mathematical function that returns the natural logarithm (base-e) for the argument.
LN()
returns a value with a DOUBLE
data type. If the argument value or the computed value exceeds DOUBLE
precision, an error is returned.
A NULL
is returned if the argument is NULL
or less than or equal to zero.
EXAMPLES
SELECT LN(1), LN(10);
+-------+----------------+
| LN(1) | LN(10) |
+-------+----------------+
| 0 | 2.302585092994 |
+-------+----------------+
SELECT LN(0);
+-------+
| LN(0) |
+-------+
| NULL |
+-------+