Nulls and Comparison Operators - Teradata Database

Teradata Database Design

Product
Teradata Database
Release Number
15.10
Language
English (United States)
Last Update
2018-10-06
Product Category
Software

Nulls and Comparison Operators

If either operand of a comparison operator is null, then the result is unknown and an error is returned to the requestor. The following examples indicate this behavior.

 

WHEN the expression is …

THEN the result is …

AND this error message returns to the requestor …

5 = NULL

Unknown

3731

5 <> NULL

NULL = NULL

NULL <> NULL

5 = NULL + 5

Note that if the argument of the NOT operator is unknown, the result is also unknown. This evaluation translates to FALSE as a final boolean result.