🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: SQL Interview Queries: all 10 questions

Quiz: SQL Interview Queries · Question 9 of 10

Which query lists employees who have no manager?

Which query lists employees who have no manager?

  1. A.SELECT name FROM employees WHERE manager_id IS NULL
  2. B.SELECT name FROM employees WHERE manager_id = NULL
  3. C.SELECT name FROM employees WHERE manager_id = 0
  4. D.SELECT name FROM employees GROUP BY manager_id
Answer & explanation

Correct answer: SELECT name FROM employees WHERE manager_id IS NULL

NULL must be tested with IS NULL; here it returns Asha.

Can you get the rest right without peeking?

Take the timed Quiz: SQL Interview Queries quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →