Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Community
I need the sum values please for the next 3 months from last year based on today's date
So, we are November 2018, my model should then pick December 2017, Jan 2018, Feb 2018 figures, Sum these up and i need the total for forecast budgeting
Example
Date Quantity
'
.
.
30/10/2017 40
10/11/2017 90
15/12/2017 50
15/01/2018 30
25/01/2018 70
21/02/2018 20
25/02/2018 10
27/02/2018 60
13/03/2018 30
.
.
.
.
So if i reload the model now, The model should give me a total of 240 [ Dec 2017 + Jan 2018 + Feb 2018 ]
I want this figure to be column where the calculation is done in SQL section please not on the object
It would be sthing like:
sum({<Date={">=$(=addmonths(date(today(1)),-12))<=$(=addmonths(date(today(1)),-10))"}>}Measure)
Try Creating Month-Year field in your script and then use it in your presentation layer for calculation.