NULL and the LEFT JOIN trapConcept

Concept

How completeness checks return nothing

NULL = 'x' is never true. A LEFT JOIN with a WHERE condition on the right-hand table turns into an inner join, dropping exactly the missing rows you were looking for. Put the condition in ON, and always write IS NULL, never = NULL.

0/5 answered · Enter to check