Your question is Cohort Rolling Conversion Rate. Start with the requirements and the two tables on the right.
Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.
GoDaddy wants to monitor conversion performance for customers who begin using products such as Websites and Domains. Write a PostgreSQL query that calculates a 7-day rolling conversion rate for each customer cohort and active event date.
user_id.cohort_date and event_date. A non-null converted_at indicates a conversion.Only cohort dates with at least one funnel event are required in the output.
| Column | Type | Description |
|---|---|---|
| user_idPK | INT | Unique customer identifier |
| cohort_date | DATE | Date the customer entered the cohort |
| product_name | VARCHAR(100) | GoDaddy product associated with the customer |
| Column | Type | Description |
|---|---|---|
| event_idPK | INT | Unique funnel event identifier |
| user_id | INT | Customer who generated the event |
| event_date | DATE | Date of funnel activity |
| converted_at | TIMESTAMP | Conversion timestamp, or NULL when the event did not convert |