Write a SQL query to track Nintendo of America retail rollout performance by location, comparing planned versus actual delivery dates and summarizing delays by region.
Use the provided location and delivery data. Include locations without a completed delivery, and treat missing planned or actual dates explicitly.
planned_delivery_date, actual_delivery_date, delay_days, delivery_status, region_avg_delay_days, and delayed_location_count.region, then location_name.| Column | Type | Description |
|---|---|---|
| location_idPK | INT | Unique retail rollout location identifier |
| location_name | VARCHAR(100) | Retail location name |
| region | VARCHAR(50) | Nintendo of America operating region |
| Column | Type | Description |
|---|---|---|
| delivery_idPK | INT | Unique delivery record identifier |
| location_id | INT | Referenced rollout location |
| planned_date | DATE | Scheduled delivery date |
| actual_date | DATE | Actual completed delivery date |