Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
HI,
I have a bar chart where I have Year as a dimension. However, for the required measure, there are missing values for a lot of Years and hence it is coming as blank. I want to remove these years from my bar graph.
please find image for reference .
I just want to keep 2020-2022 .
@User0 Try using the Set expression like below: Let me know if this worked.
Sum({<Year={'2020','2021','2022'}>}LineSalesAmount)
@User0 or to make it more dynamic, you can use the below expression:
Sum({<Year={">=$(=Max(Year)-2)<=$(=Max(Year))"}>}LineSalesAmount)
I found another solution ,
We can go to chart properties -> Add ons -> uncheck 'include null values'
@User0 Try using the Set expression like below: Let me know if this worked.
Sum({<Year={'2020','2021','2022'}>}LineSalesAmount)
@User0 or to make it more dynamic, you can use the below expression:
Sum({<Year={">=$(=Max(Year)-2)<=$(=Max(Year))"}>}LineSalesAmount)
thank you @sidhiq91
I found another solution ,
We can go to chart properties -> Add ons -> uncheck 'include null values'