Problem
I have a table in Excel with a date range and quantities. I need to sum the quantities based date range from today and older then 30, 60, 90, etc days.
Logic
- If the product was created within 30 days SUM qty.
- If the product was created between 30 days and 60days, SUM qty.
- If the product was created between 60 days and 90days, SUM qty.
Expected Results
- Qty would equal to 24 (24)
- Qty would equal to 32 (12+11+9)
- Qty would equal to 26 (10+1+10+5)
Table
CREATED AT QTY
01/02/2016 10
01/02/2016 1
03/02/2016 10
05/02/2016 5
01/03/2016 12
02/03/2016 11
06/03/2016 9
12/03/2016 24