Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi Everyone,
I have a dataset similar to the below.
Date | Job ID | % Achieved | Calculated % Achieved |
01/01/2022 | 1 | 10 | 10 |
02/01/2022 | 2 | 20 | 20 |
03/01/2022 | 3 | 30 | 30 |
04/01/2022 | 4 | 40 | 40 |
05/01/2022 | 5 | 50 | 20 |
Using the above data in a table visual, I want to be able to highlight a cell when the '% Achieved' is different from the 'Calculated % Achieved'.
For example, the above dataset would highlight 'Job ID' '5' on the '% Achieved' column as it has different values for '% Achieved' and 'Calculated % Achieved'.
Any ideas on how this can be achieved?
Solved! Go to Solution.
Hello,
I am not sure if it will work for you, but it worked for my scenario.
Please create a new measure and label it.
Test=VAR chk(Sum(Table ID[JobID%]
Var chk2(Sum(TableID[AchievedCalculater%]
Return IF(Chk=Chk2,"#aaaaa","#bbbbb")
After you enter the measure, go to the conditional formatting for the row you want, select field value, values only, and the measure you created. Select ok, and your table should refresh. Please let me know if it helps.
HI @Anonymous,
I'd like to suggest you create a measure formula to check and compare values to return color code, then you can use it in conditional formatting:
Apply conditional table formatting in Power BI - Power BI | Microsoft Docs
If you are confused about the coding formula, please share some dummy data and the measure formulas that you mention in the above sample:
Regards,
Xiaoxin Sheng
Thanks for your response.
I am confused on how to create a measure reffering to two columns in order to conditional format different values in the same row.
Sample dataset:
Date | Job ID | % Achieved | Calculated % Achieved |
01/01/2022 | 1 | 10 | 10 |
02/01/2022 | 2 | 20 | 20 |
03/01/2022 | 3 | 30 | 30 |
04/01/2022 | 4 | 40 | 40 |
05/01/2022 | 5 | 50 | 20 |
Bold text shown above will need to be highlighted as it shows two different values in the same row.
Hope this helps.
Hello,
I am not sure if it will work for you, but it worked for my scenario.
Please create a new measure and label it.
Test=VAR chk(Sum(Table ID[JobID%]
Var chk2(Sum(TableID[AchievedCalculater%]
Return IF(Chk=Chk2,"#aaaaa","#bbbbb")
After you enter the measure, go to the conditional formatting for the row you want, select field value, values only, and the measure you created. Select ok, and your table should refresh. Please let me know if it helps.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
72 | |
71 | |
57 | |
38 | |
36 |
User | Count |
---|---|
81 | |
67 | |
61 | |
46 | |
45 |