How would you approach the analysis of complex data sets and the creation of supporting graphs?
Write a SQL query that prepares a graph-ready summary of valid readings from active meters during the first quarter of 2025. Include only readings with a non-null usage value and produce one row for each month, municipality, and customer type represented in the data.
month, municipality, customer_type, total_kwh, reading_count, and avg_kwh_per_reading| Column | Type | Description |
|---|---|---|
| meter_idPK | INT | Unique meter identifier |
| municipality | VARCHAR(100) | Municipality where the meter is installed |
| customer_type | VARCHAR(30) | Customer classification |
| status | VARCHAR(20) | Meter lifecycle status |
| Column | Type | Description |
|---|---|---|
| reading_idPK | INT | Unique reading identifier |
| meter_id | INT | Referenced meter |
| reading_date | DATE | Date on which usage was recorded |
| kwh | NUMERIC(10,2) | Measured electricity usage in kilowatt-hours |