Your question is Running Total Over Telecom Usage. Start with the requirements and the two tables 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.
Rakuten Symphony's network operations teams need a chronological view of completed telecom usage by service region. Write a PostgreSQL query that aggregates usage by region and day, then calculates a running total for each region.
| Column | Type | Description |
|---|---|---|
| site_idPK | INTEGER | Unique network site identifier |
| site_name | VARCHAR(100) | Human-readable site name |
| region | VARCHAR(50) | Service region containing the site |
| Column | Type | Description |
|---|---|---|
| event_idPK | INTEGER | Unique usage event identifier |
| site_id | INTEGER | Network site associated with the event |
| usage_date | DATE | Date of recorded usage |
| usage_mb | NUMERIC(12,2) | Usage volume in megabytes |
| event_status | VARCHAR(20) | Usage event processing status |