mau_activity (activity_id, user_id, active_at) logs user activity; active_at is a UTC timestamp. A user is active in a month when they have at least one activity in that calendar month.
For each month, sort the users into:
- •new — active this month and in no earlier month
- •retained — active this month and last month
- •resurrected — active this month, not last month, but in some month before that
- •churned — active last month but not this month
Report every calendar month from the first month with any activity to the last, including months in which nobody was active. In the first month nobody can be retained, resurrected or churned.
Columns: month (a DATE, the first day of the month), active_users, new_users, retained_users, resurrected_users, churned_users. Sort by month.