Skip to content
Theory · Subqueries · lesson 6 of 11

NOT IN and NULL

In the chapter on joins you found customers without orders with LEFT JOIN and IS NULL. With a subquery the same task reads almost like a plain sentence: "customers whose number is not in the list of buyers".

In this lesson

  • What NOT IN expands into
  • NOT EXISTS is not afraid of NULL
  • Three ways to find rows without a pair
  • Key points