Compute each customer's spend per month in which they ordered. Return customer_id, month (YYYY-MM), spend and change: the difference from their previous ordering month's spend (NULL for their first). Sort by customer_id, then month.
Unlock this and every premium problem across all tracks — plus hidden-test grading, advanced AI engineering modules and new content every week.
Start 7-day free trial