Get started
Load & manage data
Work with data
Administration
Reference & resources
CLUSTER BY
mask
ROW FILTER
Updated Oct 04, 2024
Send us feedback
nullif
Applies to: Databricks SQL Databricks Runtime
Returns NULL if expr1 equals expr2, or expr1 otherwise.
NULL
expr1
expr2
nullif(expr1, expr2)
expr1: An expression of any type.
expr2: An expression of the same type as expr.
expr
NULL if expr1 equals to expr2, or expr1 otherwise.
> SELECT nullif(2, 2); NULL > SELECT nullif(2, 3); 2
coalesce function
decode (key) function
case expression