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
mb0307
Responsive Resident
Responsive Resident

Sorting Top 5

Hi all,

 

I am showing % difference in a matrix table. 

 

How can I sort top 5 Products based on another measure, see below?

 

DOWNLOAD - DATA AND PBIX FILE

 

mb0307_0-1677658888994.png

 

 

Thank you in advance.

 

12 REPLIES 12
mb0307
Responsive Resident
Responsive Resident

Can anyone help with this please?

Padycosmos
Solution Sage
Solution Sage

Hope this helps:

Padycosmos_0-1677503997483.png

Padycosmos_1-1677504031996.png

 

mb0307
Responsive Resident
Responsive Resident

@Padycosmos thanks again but this is not the requirement.  Please read my post and files. 

mb0307_0-1677516492484.png

 

Add the measure diff to tooltips and then click on the ellipsis and select descending and diff

This video illustrates that

https://www.youtube.com/watch?v=1bp_e-ik7aA

mb0307
Responsive Resident
Responsive Resident

it doesn't work for Tables and Matrix unfortunately. 

Padycosmos
Solution Sage
Solution Sage

Here's an excerpt from a Microsoft document on TOPN() wherein it is stated that the result is not sorted in any order. So apparently, sorting has to be done manually : https://learn.microsoft.com/en-us/dax/topn-function-dax

 

Padycosmos_0-1677497351042.png

 

mb0307
Responsive Resident
Responsive Resident

@Padycosmos  thanks but I am not using TopN.  

lucadelicio
Impactful Individual
Impactful Individual

I think you have to built a calculated column with a RANKX and use it to order. But you have to pay attention to the circular dependency. If i have time a try to help you in the next day.



Luca D'Elicio

LinkedIn Profile

@lucadelicio thanks, please see if you can help with this one. As i am not sure how to do this. 

mb0307
Responsive Resident
Responsive Resident

Can anyone help please?

lucadelicio
Impactful Individual
Impactful Individual

Is this what you need?

lucadelicio_0-1677250599552.png

 



Luca D'Elicio

LinkedIn Profile

@lucadelicio  No my friend.  Please read the instruction in the PBIX

 

The Accuracy % table should show SKU in this order: 

mb0307_0-1677250902441.png

 

Thanks.

 

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.