A bank groups monthly income into three bands: 'Low Salary' for income strictly below 20000, 'Average Salary' for income from 20000 to 50000 inclusive, and 'High Salary' for income strictly above 50000. All three bands must appear in the report, even when a band has no accounts. Write an SQL query that returns category and accounts_count. The rows can be in any order.
Loading…
Try solving the question with the schema explorer and hints first. When ready, reveal the verified canonical query and step-by-step logic breakdown.
Ask questions, share alternate queries, and explore solutions
Your recent query executions and answer checks
This will insert the verified MySQL solution into your editor so you can study how each clause transforms the table.