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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
ksrini
Helper I
Helper I

Sorting and Ranking in a Matrix table

Hi All,

 

I need to create a summary table on product sales by countries and sort products by their sales in descending order. Products are in columns and regions are in rows. I also need to color top 2, 3-5 and 6-8 countries in each product. The below table is only a sample and i have much bigger table. From the below table, i am trying to get to sorting stage in which Product 3 should be the left most in the table and Product 7 has to be the last one. 

 

Regarding coloring the cells in the Product 1 column, cells with 9 and 7 should be colored green because they are top 2 and 5 and 4 should be lighter green and the next 2 ranked ones should be more lighter green. I tried few ways to sort like sorting by other column etc but i am not able to solve it. Can any guide me on this ?  

 

CountryProduct 1Product 2Product 3Product 4Product 5Product 6Product 7Product 8
USA59628 83
India 357 2  
China35   7 4
Japan7 638 8 
Germany 355    
England 5 646 5
France4 2     
Italy 159   7
Spain35   7  
Australia9 738 38
Total Sales3131363528221927

  Thanks

Srini

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @ksrini ,

I created a sample pbix file(see attachment), please check whether that is what you want.

yingyinr_0-1619427295786.png

Best Regards

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Hi @ksrini ,

I created a sample pbix file(see attachment), please check whether that is what you want.

yingyinr_0-1619427295786.png

Best Regards

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Top Solution Authors