Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey all,
I have an aggregation function and I want to exclude the month-filter (Maand) to have effect on the outcome of the sum.
Found several topics and tried several things but nothing helps. Currently the following formula is what I have:
(sum({<Maand=>}AGGR(IF(SUM({<Jaar={2022}, Collectiejaar2022 = {'2022'},Maand=>}Afzet)>=VerpakkingsEenh,1,0),Productcode)))
Thanks in advance!
try below
=(sum({<Maand=>}
AGGR({<Maand=>}
IF(SUM({<Jaar={2022}, Collectiejaar2022 = {'2022'},Maand=>}Afzet)>=VerpakkingsEenh,1,0)
,Productcode)))
Hey @vinieme12,
Thanks for your reply.
Unfortunately it doesn't work. Outcome is still affected when filtering on Maand.
do you have any calculated dimensions in the chart?
No all dimensions are directly from tables in load script editor
=(sum({<Maand=>}
AGGR({<Maand=>}
IF(SUM({<Jaar={2022}, Collectiejaar2022 = {'2022'},Maand=>}Afzet)>=SUM({<Jaar={2022}, Collectiejaar2022 = {'2022'},Maand=>}VerpakkingsEenh),1,0)
,Productcode)))
Hi Vinieme12,
This formula gives incorrect output : 0
Do you might know another solution? I read several things about Only() but don't know exactly if it can be used in my formula or how to implement it.
Thanks again!
Hi @Giel0 ,
I suggest you to use alternates states to achieve what you are looking for.
I hope it can helps.
Best Regards