Write a query to find the month-over-month growth rate of active therapists on Headway.
Treat a therapist as active when is_active is true for that month. Calculate growth only for months with a preceding calendar month, and avoid division by zero.
month, active_therapists, previous_active_therapists, and growth_rate_pct| Column | Type | Description |
|---|---|---|
| month_startPK | DATE | First day of a reporting calendar month |
| Column | Type | Description |
|---|---|---|
| activity_idPK | INT | Unique monthly activity record |
| therapist_id | INT | Therapist identifier |
| month_start | DATE | Reporting month for the activity record |
| is_active | BOOLEAN | Whether the therapist was active during the month |