Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi team,
I have bar chart and i want to chnage the values of dimention based on user selction.
I have variable which will have the value which user will select. I am trying to use following as dimention :
if(
vSelector='Customer', aggr(if( (sum(revenue)0) ,[CustomeDescription]),[CustomerDescription]) ,
if(vSelector='Industry',
aggr(if( (sum(revenue)0) ,[IndustryDescription]),[Industry]) ,
if(vSelector='Region',
aggr(if( (sum(revenue)0) ,region),region
) ) ) )
But this is not working as expetced . the values before adding in if else statement are different than after we will use this expression
i have measure sum(sales) which value will be calculated based on other period selector like "MTD" ,"YTD
The expression is like this not as above:
if( vSelector='Customer',
aggr(if(
(sum(revenue)<=0) or (sum([revenue])>0) ,[CustomeDescription]),[CustomerDescription]),
if(vSelector='Industry',
aggr(if(
(sum(revenue)<=0) or (sum([revenue])>0) ,[IndustryDescription]),[Industry])
,if(vSelector='Region',
aggr(if(
(sum(revenue)<=0) or (sum([revenue])>0) ,region),region)
)
)
)