Your question is Top 5 Shows by Region. Start with the requirements and the one table on the right.
Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.
Given a user engagement table, write a query to identify the top 5 most-watched shows by region.
Use all engagement records with valid region and show values. Treat NULL watch minutes as contributing nothing. Return exactly five shows per region, breaking equal totals alphabetically by show name.
region, show_name, total_watch_minutes, and region_rankregion, then region_rank| Column | Type | Description |
|---|---|---|
| engagement_idPK | INT | Unique engagement record identifier |
| region | VARCHAR(50) | User viewing region |
| show_name | VARCHAR(100) | Name of the watched show |
| watch_minutes | INT | Minutes watched in the engagement record |