The finance team needs a cumulative revenue growth chart for key markets. Show monthly revenue alongside the running cumulative total for the USA, Canada, and France.
| Column | Type |
|---|---|
| InvoiceId | INTEGER (Primary Key) |
| CustomerId | INTEGER (Foreign Key → Customer.CustomerId) |
| InvoiceDate | TIMESTAMP |
| BillingAddress | TEXT |
| BillingCity | TEXT |
| BillingState | TEXT |
| BillingCountry | TEXT |
| BillingPostalCode | TEXT |
| Total | NUMERIC(10,2) |
SUM() OVER (PARTITION BY Country ORDER BY Month) for cumulative totalCountry, Month, MonthlyRevenue, CumulativeRevenueReady to take your skills to the next level? Enroll in our comprehensive Data Analyst Career Track to master SQL, Python, Excel, and Power BI.
Run your code to see the result here.