Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Guys,
How to change this expression bellow so it gives me the value of year -1 until today 20/10
My calendar dimension contains : Calendar Date with that format : 20/10/2017
num(sum( {$<[Year of date]={$(=Max([Year of date])-1)}>} recharge_amount),'# ##0'))
Thanks in advance
Try this then
Num(Sum({$<[calendar date] = {"$(='>=' & Date(AddYears(Today(), -1), 'DD/MM/YYYY') & '<=' & Date(AddYears(Today(), 0), 'DD/MM/YYYY'))}>} recharge_amount),'# ##0'))
there is an error on the express
=Num(Sum({$<[Calendar date] = {"$(='>=' & Date(AddYears(Today(), -1), 'DD/MM/YYYY') & '<=' & Date(AddYears(Today(), 0), 'DD/MM/YYYY'))}>} recharge_amount),'# ##0'))
There is a double quote missing:
=Num(Sum({$<[Calendar date] = {"$(='>=' & Date(AddYears(Today(), -1), 'DD/MM/YYYY') & '<=' & Date(AddYears(Today(), 0), 'DD/MM/YYYY')) " }>} recharge_amount),'# ##0'))
Remove the last bracket
thanks but i need the value between, 01/01/2016 and 20/10/2016
it seems that the result between 20/10/2016 and 20/10/2017
Just adapt the dates in your search:
=Num(Sum({$<[Calendar date] = {"$(='>=' & Date(Yearstart(Today(), -1), 'DD/MM/YYYY') & '<=' & Date(AddYears(Today(), -1), 'DD/MM/YYYY')) " }>} recharge_amount),'# ##0')
Try this?
=Num(Sum({$<[Calendar date] = {"$(='>=' & YearStart(Date(AddYears(Today(), -1), 'DD/MM/YYYY')) & '<=' & Date(AddYears(Today(), -1), 'DD/MM/YYYY') " }>} recharge_amount),'# ##0'))
Try this
Num(Sum({$<[calendar date] = {"=[calendar date] >= SetDateYear(YearStart(Today()), Year(Today())) and [calendar date] <= SetDateYear(Today(), Year(Today()))"}, [Year of Date] = {">=$(=Max([Year of date])-1)"}>} recharge_amount),'# ##0'))