Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
tatipelli14
Contributor
Contributor

Bar background color issue with current selections

Hi group, I have a requirement where I have to color the bar based on dimension value picking from another field which is working fine. But when other field selections are made, this condition doesn't work.

Based on the data model, I am attaching a sample dashboard here. Anyone faced similar issue?

Labels (4)
2 Replies
_ylc
Partner - Creator
Partner - Creator

Based on your model, Customer #2 isn't associated with any Report Number. So If you select a report number, lets say 1, the Customer Name 2 is null.

Your color expression:

=if(Only({<[Report Number]=>}[Customer Name])=Only([Customer Name 2]), Green(), Red())

Customer Name: Cust1

Report Number: 1

Customer Name: null

Cust1 <> null thus output is Red()

 

The 2nd part of your condition should also ignore the Report Number selection then it will not change.

=if(Only({<[Report Number]=>}[Customer Name])=Only({<[Report Number]=>}[Customer Name 2]), Green(), Red())

Brett_Bleess
Former Employee
Former Employee

Did the partner post assist you in getting things working?  If so, do not forget to return to your thread to close things out by using the Accept as Solution button on that post to give them credit for the help and let other Members know that worked.  If you are still working on things, please leave an update with what you still need from us.

Regards,
Brett

To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.