Churned accounts and when
Your task
List the subscriptions that were cancelled. Return id and cancelled_on, earliest cancellation first.
Tables
account
| idINTEGER | nameTEXT | tierTEXT |
|---|---|---|
| 1 | Northwind | team |
| 2 | Acme | solo |
| 3 | Globex | team |
| 4 | Initech | solo |
subscription
| idINTEGER | account_idINTEGER | started_onTEXT | cancelled_onTEXT | mrr_centsINTEGER |
|---|---|---|---|---|
| 1 | 1 | 2025-06-01 | NULL | 49000 |
| 2 | 2 | 2025-08-15 | 2026-01-31 | 9000 |
| 3 | 3 | 2025-09-01 | NULL | 49000 |
| 4 | 4 | 2026-01-05 | 2026-02-20 | 9000 |
| 5 | 2 | 2026-02-01 | NULL | 19000 |