Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi experts
I have this formula in a dimension:
=[Timestamp.autoCalendar.YearMonth]={'>=$(=Monthstart(Addmonths(Max(Timestamp.autoCalendar.YearMonth),-11)))<=$(=MonthEnd(Max(Timestamp.autoCalendar.YearMonth)))'}
It gives an error in expression although the result is shown in the information bar:
Where is the error?
Thanks.
H, that's not a full expression, it's just a set analysis. Set analysis it's just a filter for data, but it needs the rest of the expression to know what to do with that data, ie:
Sum({<[Timestamp.autoCalendar.YearMonth]={'>=$(=Monthstart(Addmonths(Max(Timestamp.autoCalendar.YearMonth),-11)))<=$(=MonthEnd(Max(Timestamp.autoCalendar.YearMonth)))'}>} Value)
BTW, to use operators like >= or <= the syntax is with double quotes, simple quotes is used to look for exact coincidence of strings.
[Timestamp.autoCalendar.YearMonth]={">=$(=Monthstart(Addmonths(Max(Timestamp.autoCalendar.YearMonth),-11)))<=$(=MonthEnd(Max(Timestamp.autoCalendar.YearMonth)))"}