← All courses
Course review & final exams
Final exam: SQL & databases
10 new questions you haven't seen in the exercises. The pass mark is 7. Answer them all, then press “Grade”.
1. Which query returns only customers from Riyadh?
2. What's the difference between WHERE and HAVING?
3. Which JOIN returns every customer, even those with no orders?
4. A foreign key's job is to:
5. How many rows does SELECT COUNT(*) FROM orders; return for 120 orders?
6. A column holds several phone numbers separated by commas. Which normal form does it break?
7. In (emp_id, dept_id, dept_name), dept_name depends on dept_id, not the key. This breaks:
8. Which command changes an existing product's price?
9. You forget WHERE in DELETE FROM orders; what happens?
10. ORDER BY total DESC LIMIT 3 returns:
10 unanswered