Your question is Top Customers SQL Query. 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.
Pyramid Consulting's account-sales pipeline records individual sales activity by customer. Write a PostgreSQL query to identify the top 10 customers by total sales volume.
sales_volume.customer_id as a secondary ascending sort for deterministic results.| Column | Type | Description |
|---|---|---|
| sales_idPK | INT | Unique identifier for a sales activity record. |
| customer_id | INT | Identifier for the customer account. |
| customer_name | VARCHAR(100) | Name of the customer account. |
| sales_volume | NUMERIC(12,2) | Sales volume associated with the activity. |
| sales_date | DATE | Date the sales activity was recorded. |