Customers Above Average Spend
MediumDescription
A customer's spend is the sum of total_amount over all their orders. Show customer_id,
full_name and spent for the customers whose spend is above the average spend of the
customers who have ordered.
End your query with ORDER BY spent DESC, customer_id.
Tables
| customers |
|---|
| customer_id (PK) |
| full_name |
| orders |
|---|
| order_id (PK) |
| customer_id (FK) |
| total_amount |