Get started
Load & manage data
Work with data
Administration
Reference & resources
CLUSTER BY
mask
ROW FILTER
Updated Nov 04, 2024
Send us feedback
nanvl
Applies to: Databricks SQL Databricks Runtime
Returns expr1 if it’s not NaN, or expr2 otherwise.
expr1
NaN
expr2
nanvl(expr1, expr2)
expr1: An expression that evaluates to a numeric.
expr2: An expression that evaluates to a numeric.
A DOUBLE.
> SELECT nanvl(cast('NaN' AS DOUBLE), 123); 123.0
coalesce function