isnan function

Applies to: check marked yes Databricks SQL check marked yes Databricks Runtime

Returns true if expr is NaN.

Syntax

isnan(expr)

Arguments

  • expr: An expression that evaluates to a numeric.

Returns

A BOOLEAN.

Examples

> SELECT isnan(cast('NaN' as double));
 true
> SELECT isnan(7);
 false