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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Anonymous
Not applicable

Row wise Table Visual Conditional formatting between columns

Hi All,

 

I have table visual where it has product wise Total sales and each monthly growth % as columns.

MohanV128256_0-1691083415776.png

As per my knowledge i am able to do the conditional formatting for each individual column from Jan% to May% using the individual columns as

Ex: for Jan% 

MohanV128256_1-1691083547713.png

But, my requirement is to do conditional formatting between the columns from Jan% to May% only for each product wise row. 

 

Can anyone help me or suggest how it can be done.

 

Thanks,

Mohan V.

4 REPLIES 4
Anonymous
Not applicable

@kpost  this is not  a optimized solution or approch i would say...i need to build the conditions like 12!.

 

Any other  better solution for this.

kpost
Super User
Super User

This question is very similar to one I answered yesterday.  the only difference is that, instead of social media companies, you are adding row-level conditional formatting using product names.

Check this answer here.  Let me know if you have trouble.

https://community.fabric.microsoft.com/t5/Desktop/Conditional-Formatting-with-IF-statement/m-p/33622...

//Mediocre Power BI advice, but it's free//

Anonymous
Not applicable

@kpost you mean, write all the combinations of conditions and give the numbering then use it in conditional formatting like below.

 

Jan% Colour Grading = 
VAR Jan = SUM(MASTER_2023_Promo[January])
VAR Feb = SUM(MASTER_2023_Promo[February])
VAR Mar = SUM(MASTER_2023_Promo[March])
VAR Apr = SUM(MASTER_2023_Promo[April])
VAR May = SUM(MASTER_2023_Promo[May])
VAR Jun = SUM(MASTER_2023_Promo[June])
VAR Jul = SUM(MASTER_2023_Promo[July])
VAR Aug = SUM(MASTER_2023_Promo[August])
VAR Sep = SUM(MASTER_2023_Promo[September])
VAR Oct = SUM(MASTER_2023_Promo[October])
VAR Nov = SUM(MASTER_2023_Promo[November])
VAR Dec = SUM(MASTER_2023_Promo[December])
RETURN
SWITCH(TRUE(),
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,0,

Jan > Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,1,
Jan > Feb && Jan > Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,2,
Jan > Feb && Jan > Mar && Jan > Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,3,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,4,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,5,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,6,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,7,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan < Oct && Jan < Nov && Jan < Dec,8,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan < Dec,9,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,10,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,11,


Jan < Feb && Jan > Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,12,
Jan < Feb && Jan > Mar && Jan > Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,13,
Jan < Feb && Jan > Mar && Jan > Apr && Jan > May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,14,
Jan < Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,15,
Jan < Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,16,
Jan < Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,17,
Jan < Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan < Oct && Jan < Nov && Jan < Dec,18,
Jan < Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan < Dec,19,
Jan < Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,20,
Jan < Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,21,


Jan < Feb && Jan < Mar && Jan > Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,22,
Jan < Feb && Jan < Mar && Jan > Apr && Jan > May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,23,
Jan < Feb && Jan < Mar && Jan > Apr && Jan > May && Jan > Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,24,
Jan < Feb && Jan < Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,25,
Jan < Feb && Jan < Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,26,
Jan < Feb && Jan < Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan < Oct && Jan < Nov && Jan < Dec,27,
Jan < Feb && Jan < Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan < Dec,28,
Jan < Feb && Jan < Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,29,
Jan < Feb && Jan < Mar && Jan > Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,30,

Jan < Feb && Jan < Mar && Jan < Apr && Jan > May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,31,
Jan < Feb && Jan < Mar && Jan < Apr && Jan > May && Jan > Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,32,
Jan < Feb && Jan < Mar && Jan < Apr && Jan > May && Jan > Jun && Jan > Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,33,
Jan < Feb && Jan < Mar && Jan < Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,34,
Jan < Feb && Jan < Mar && Jan < Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan < Oct && Jan < Nov && Jan < Dec,35,
Jan < Feb && Jan < Mar && Jan < Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan < Dec,36,
Jan < Feb && Jan < Mar && Jan < Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,37,
Jan < Feb && Jan < Mar && Jan < Apr && Jan > May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,38,

Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan > Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,39,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan > Jun && Jan > Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,40,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan > Jun && Jan > Jul && Jan > Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,41,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan < Oct && Jan < Nov && Jan < Dec,42,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan < Dec,43,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,44,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan > Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,45,

Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan > Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,46,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan > Jul && Jan > Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,47,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan < Oct && Jan < Nov && Jan < Dec,48,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan < Dec,49,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,50,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,51,


Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan > Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan < Dec,52,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan > Aug && Jan > Sep && Jan < Oct && Jan < Nov && Jan < Dec,53,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan < Dec,54,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,55,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,55,


Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan > Sep && Jan < Oct && Jan < Nov && Jan < Dec,56,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan < Dec,57,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,58,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,59,

Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan > Oct && Jan < Nov && Jan < Dec,60,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan > Oct && Jan > Nov && Jan < Dec,61,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan > Oct && Jan > Nov && Jan > Dec,62,

Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan > Nov && Jan < Dec,63,
Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan > Nov && Jan > Dec,64,


Jan < Feb && Jan < Mar && Jan < Apr && Jan < May && Jan < Jun && Jan < Jul && Jan < Aug && Jan < Sep && Jan < Oct && Jan < Nov && Jan > Dec,65,

Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun  && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,66,

Jan > Feb && Jan < Mar && Jan > Apr && Jan > May && Jan > Jun  && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,67,
Jan > Feb && Jan > Mar && Jan < Apr && Jan > May && Jan > Jun  && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,68,
Jan > Feb && Jan > Mar && Jan > Apr && Jan < May && Jan > Jun  && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,69,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan < Jun  && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,70,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun  && Jan < Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,71,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun  && Jan > Jul && Jan < Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan > Dec,72,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun  && Jan > Jul && Jan > Aug && Jan < Sep && Jan > Oct && Jan > Nov && Jan > Dec,73,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun  && Jan > Jul && Jan > Aug && Jan > Sep && Jan < Oct && Jan > Nov && Jan > Dec,74,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun  && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan < Nov && Jan > Dec,75,
Jan > Feb && Jan > Mar && Jan > Apr && Jan > May && Jan > Jun  && Jan > Jul && Jan > Aug && Jan > Sep && Jan > Oct && Jan > Nov && Jan < Dec,76
)

The number that is returned on each line should correspond to the color you want the cell to be, given the fact that the logical statement is true.  For example 1 might be green, 2 might be red, 3 might be orange etc.

Right now you are returning numbers 1 through 76, implying there are 76 different colors you want to use.

 

But yes you appear to understand the general idea, assuming you know what you're going to use those 76 numbers for 

//Mediocre Power BI Advice, but it's free//

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.