SUM and COUNT when no row matches
QuizMedium
No order has the status RETURNED. What does this query return?
SELECT SUM(amount), COUNT(*) FROM orders WHERE status = 'RETURNED';
- One row: NULL and 0
- One row: 0 and 0
- No rows at all
- An error
This question is part of Pro+
Pro+ opens every question in Interview Prep and the mock interview. Every article and the first 2 questions of each topic stay free. Hands-on Selenium and API tasks follow their course lesson's own lock.