Reply
avatar user
Anonymous
Not applicable
Partially syndicated - Outbound

Conditional Formatting - Matrix Table

Hi Team,

 

I have below table and created Matric table in PI file, now I need to highlight rows wise if value mismatch.

Img1.PNG 

1 ACCEPTED SOLUTION

Syndicated - Outbound

So if I understood correctly all values in the same category should be the same, otherwise be highlighted. Find attached my proposed solution. I adapted @NikhilChenna 's recommendation into this formula:

Color Logic = IF(SUM('Table'[Cat14]) <> SUM('Table'[Cat15]) || SUM('Table'[Cat14])<> SUM('Table'[Cat16]) || SUM('Table'[Cat15])  <> SUM('Table'[Cat16]), "#FF7F7F", "#FFFFFF") 

You would need to pivot your table though, assuming you don't have other data. 

ray_aramburo_0-1710951948716.png

 





Did I answer your question? Give your kudos and mark my post as a solution!

Proud to be a Super User!





View solution in original post

8 REPLIES 8
NikhilChenna
Skilled Sharer
Skilled Sharer

Syndicated - Outbound

Hi @Anonymous ,

Please follow the below steps to get your conditional formatting, 

  1. Select the matrix visual in Power BI Desktop.
  2. Click on the "Format" pane (paint roller icon) on the right side.
  3. Under the "Values" section, select the field that corresponds to the values in columns 14, 15, and 16.
  4. Scroll down to the "Conditional formatting" section and click on the ellipsis (...) button.
  5. Choose "Background color scales" or "Font color scales" based on your preference.
  6. In the "Minimum" and "Maximum" conditions, set the rules for when the entire row should be colored.
  7. For your case, you want to color the row when the values in columns 14, 15, and 16 do not match. You can use the following steps:
    1. Click on "Add rule." 
    2. Set the condition as "is not equal to." 
    3. Specify the field or value for comparison. You may need to write a DAX expression to compare the values in columns 14, 15, and 16. For example, if your fields are named [Column14], [Column15], and [Column16], the DAX expression could be something like:
       
      =IF([Column14] <> [Column15] || [Column14] <> [Column16] || [Column15] <> [Column16], 1, 0
       
      4. Set the color for when this condition is met.
  8. Click "OK" to apply the conditional formatting.

These steps should help you achieve the desired result of coloring the entire row when the values in columns 14, 15, and 16 do not match. Adjust the DAX expression and conditional formatting rules as per your specific dataset and requirements.

 

Regards,

Nikhil Chenna

 

If your issues resolves select my post as a solution and gives a thumbsup.

avatar user
Anonymous
Not applicable

Syndicated - Outbound

Hi @NikhilChenna 
If the 14,15 and 16 is the single column then what is the dax function, Please advise

Syndicated - Outbound

Hi @Anonymous ,

You can try the below ,

=IF([Value] <> EARLIER([Value]), 1, 0)

Regards,

Nikhil Chenna

If your issues resolves select my post as a solution and gives a thumbsup.

ray_aramburo
Super User
Super User

Syndicated - Outbound

What would be the criteria to determine if a value is a mismatch?





Did I answer your question? Give your kudos and mark my post as a solution!

Proud to be a Super User!





avatar user
Anonymous
Not applicable

Syndicated - Outbound

Hi @ray_aramburo 
Entire row highlight amber color

 

Syndicated - Outbound

Which values do you want to compare I meant?





Did I answer your question? Give your kudos and mark my post as a solution!

Proud to be a Super User!





avatar user
Anonymous
Not applicable

Syndicated - Outbound

Img2.PNG

Syndicated - Outbound

So if I understood correctly all values in the same category should be the same, otherwise be highlighted. Find attached my proposed solution. I adapted @NikhilChenna 's recommendation into this formula:

Color Logic = IF(SUM('Table'[Cat14]) <> SUM('Table'[Cat15]) || SUM('Table'[Cat14])<> SUM('Table'[Cat16]) || SUM('Table'[Cat15])  <> SUM('Table'[Cat16]), "#FF7F7F", "#FFFFFF") 

You would need to pivot your table though, assuming you don't have other data. 

ray_aramburo_0-1710951948716.png

 





Did I answer your question? Give your kudos and mark my post as a solution!

Proud to be a Super User!





avatar user

Helpful resources

Announcements
March PBI video - carousel

Power BI Monthly Update - March 2025

Check out the March 2025 Power BI update to learn about new features.

March2025 Carousel

Fabric Community Update - March 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors (Last Month)
Top Kudoed Authors (Last Month)