three-valued logic

SQL's rule that a condition can be true, false or unknown, where unknown comes from comparing with NULL.

In more detail

WHERE keeps a row only when its condition is true, so unknown behaves like false in a filter. NOT unknown is still unknown, which is why NOT IN with a NULL in its list returns nothing. CHECK constraints, by contrast, accept a row unless the condition is false.

Related terms

Taught in

References