Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have the following expression:
Sum (if ((Year = CurrentYear) and (Week <= ($(VECKANRTMP)+10)), SalesBudEUR))
And I want to turn it into a set expression instead. But I'm not sure about how to integrate the +10 modifier.
Try with
=Sum ({<Year = {$(=CurrentYear)}, Week={"<=$(=VECKANRTMP+10)"} >} SalesBudEUR)
I am assuming, These are variables? Perhaps this?
Sum ({<Year = {$(CurrentYear)}, Week={"<=($(VECKANRTMP)+10)"} SalesBudEUR)
OR
Sum ({<Year = {$(CurrentYear)}, Week={"$('<=' & VECKANRTMP+10)"} SalesBudEUR)
CurrentYear and VECKANRTMP are both variables, yes.
Unfortunately, the solutions you provided does not work. It shows no data at all.
Perhaps I should explain my question further:
The Sum (if ((Year = CurrentYear) and (Week <= ($(VECKANRTMP)+10)), SalesBudEUR))is a sum of the annual budget for the current year (Year = CurrentYear) and then displaying the budget per week in a bar chart for the coming 10 weeks (Week <= ($(VECKANRTMP)+10)).
My bad, I missed $ sign here, May be?
Sum ({<Year = {$(=CurrentYear)}, Week={"<=$(=VECKANRTMP)+10)"} SalesBudEUR)
Still no luck
I tried to close the expressions as well:
Sum ({<Year = {$(=CurrentYear)}, Week={"<=$(=VECKANRTMP)+10)" >} SalesBudEUR)
Try with
=Sum ({<Year = {$(=CurrentYear)}, Week={"<=$(=VECKANRTMP+10)"} >} SalesBudEUR)
There we go!
It works as intended - Thanks a lot. Also big thanks to @Anil Babu!
A good tip for debugging these kind of problems is to create a straight table where you leave the label for the expression blank. The header of the table will diaplay how the $ sign expansions are evaluated like