Write a SQL query to identify the top 10% of customers based on specific usage metrics.
Use usage records from calendar year 2025. Rank every customer by completed usage units, then active usage days and completed usage events as tie-breakers. Include customers with no qualifying usage, and return only the highest decile.
customer_id, customer_name, total_usage_units, active_usage_days, completed_usage_events, and usage_decile.| Column | Type | Description |
|---|---|---|
| customer_idPK | INT | Unique customer identifier |
| customer_name | VARCHAR(100) | Customer display name |
| Column | Type | Description |
|---|---|---|
| event_idPK | INT | Unique usage event identifier |
| customer_id | INT | Customer associated with the usage event |
| event_date | DATE | Date on which usage occurred |
| usage_units | INT | Units recorded for the usage event |
| status | VARCHAR(20) | Event processing status |