Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hello Community,
My dataset Resume : Player# | Label| Value
Label can be "TOPS", "Competition", "Management", "Training"
Value is the value of the Label
I want to show a colour based on the value and the Label
ColumnColour =
VAR ValueCompet = CALCULATE(MAX('Resume'[Value]), 'Resume'[Label] = "Competition")
VAR ValueTrain = CALCULATE(MAX('Resume'[Value]), 'Resume'[Label] = "Training")
VAR RLabel = 'Resume'[Label]
VAR RValue = 'Resume'[Value]
RETURN
SWITCH(
TRUE(),
RLabel = "Management",
SWITCH(
TRUE(),
RValue >= 150, "Green",
RValue >= 90, "Yellow",
TRUE(), "Red"
),
RLabel = "TOPS"
SWITCH(
TRUE(),
ValueTrain < ValueCompet, "Green",
ValueTrain = ValueCompet, "Yellow",
TRUE(), "Red"
)
)
The issue lies with the last label "TOPS", where it consistently displays "Yellow" for all players. When the label is "TOPS", it only considers the value of "TOPS" instead of taking into account the comparison between `ValueEntr` and `ValueCompet`.
After several attempts, I focused solely on the condition where Label equals TOP.
ColumnColour =
IF(Resume[Label] = "TOPS", CALCULATE(MAX(Resume[Value]), FILTER(Resume, Resume[Label] = "Training")))
and the result is blank.
The idea is how to display the value of "Training" where Label = TOPS. This is the root problem that's why the comparison doesn't work.
How can this be rectified?
Thank you
Solved! Go to Solution.
You are my Savior JamesFR06 Thank you so much
Merci beaucoup 😍
HI,
Just add allexcept after your max calculations