not operator

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

Returns logical negation of the argument. This operator is an alias for ! (bang sign) operator.

Syntax

not expr

Arguments

  • expr: A BOOLEAN expression.

Returns

A BOOLEAN.

Examples

> SELECT not true;
 false
> SELECT not false;
 true
> SELECT  not NULL;
 NULL