LN
Syntax
%%{init: {
'theme': 'base',
'flowchart': { 'padding': '7', 'nodeSpacing': '20', 'rankSpacing': '20' },
'themeVariables': {
'fontSize': '11px',
'fontFamily': 'Arial'
}
}}%%
flowchart LR
Start((START)) --> LN[LN]:::quoted
LN --> End((END))
Purpose
The LN SQL function gets the natural logarithm of a number. In contrast to LOG, no base can be specified; the base is always the number e.
Parameters:
- Input (
decimal): a number to get the natural logarithm from.
Returns: the natural logarithm of the input.
Examples
The following example retrieves the natural logarithm of 1:
select ln(1)
-------------------
0
The following example retrieves the natural logarithm of the number e:
select ln(exp(1))
-------------------
1