Three-Month Moving Average
MediumDescription
v_monthly_sales is a view with one row per month. For the months of 2025, show
month, revenue and moving_avg: the average revenue of that month and the two months before
it, rounded to 2 decimal places. January and February have fewer months before them in 2025, so
they average only the months available.
End your query with ORDER BY month.
Tables
| v_monthly_sales |
|---|
| month |
| revenue |