3 Month Moving Average - Redshift SQL
问题 I am trying to create a 3 Month Moving Average based on some data that I have while using RedShift SQL or Domo BeastMode (if anyone is familiar with that). The data is on a day to day basis, but needs to be displayed by month. So the quotes/revenue need to be summarized by month, and then a 3MMA needs to be calculated (excluding the current month). So, if the quote was in April, I would need the average of Jan, Feb, Mar. The input data looks like this: Quote Date MM/DD/YYYY Revenue 3/24/2015