$ ./guess_the_languageProblem Solving — fix the bug
Problem Solving — fix the bug · easy · #222

Which fix removes the bug?

SELECT name FROM users
WHERE email = NULL;
-- expected: users without an email
  1. Write email == NULL
  2. Write email IS NULL
  3. Write email = 'NULL'
  4. Write email <> NULL
Any comparison with NULL using = is unknown, never true; IS NULL is the test for missing values.
Play Problem Solving ▸