Return
day: the datetotal_revenue: total revenue across all regions for that daysignup_count: number of signups on that dayavg_revenue_per_signup: average revenue per signup on that daysignup_count is greater than zero, and order the results by day in ascending order.Expected output
| day | total_revenue | signup_count | avg_revenue_per_signup |
|---|---|---|---|
| 2023-01-01 | 900 | 25 | 36 |
| 2023-01-02 | 1786 | 92 | 19.41304347826087 |
| 2023-01-03 | 1772 | 24 | 73.83333333333333 |
First 3 of 41 rows your query should return. Your column aliases don't need to match.
daily_sales
| day | region | revenue | orders |
|---|---|---|---|
| 2023-01-01 | US | 490 | 10 |
| 2023-01-02 | US | 1028 | 21 |
| 2023-01-03 | US | 966 | 19 |
| 2023-01-04 | US | 1014 | 20 |
| 2023-01-05 | US | 1062 | 21 |
signups
| day | signup_count |
|---|---|
| 2023-01-01 | 25 |
| 2023-01-02 | 92 |
| 2023-01-03 | 24 |
| 2023-01-04 | 66 |
| 2023-01-05 | 108 |
0 of 4 hints revealed
Submit an attempt first.