๐ณ Not All Customers Are Equal.
The VIP team at Citi cards segments customers into tiers based on monthly spend. Anyone spending above $5,000 in a month qualifies for the Platinum tier and gets a dedicated relationship manager.
Find all customers who crossed $5,000 in spend in any single month of 2024. Return customer_id, month (YYYY-MM format), and monthly_spend. Order by monthly_spend descending.
transactions Table:
| Column | Type |
|---|---|
| txn_id | integer |
| customer_id | integer |
| amount | integer |
| txn_date | text |
Expected Outcome (Illustrative Sample):
| customer_id | month | monthly_spend |
|---|---|---|
| 1006 | 2024-04 | 6800 |