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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

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
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors