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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
matkvaid
Helper III
Helper III

Is this possible, TOPN as matrix rows?

Hi, i am asked to do something like this - compare table. I have the measures, results are ok, but now i am also asked to make just top product comparing, i would put it in a matrix, but do not find a way how to... Any ideas is it possible?

 

 Measure1Measure2Measure3
Top10080%20%-5%
Top1050%50%-10%
Top320%80%5%
6 REPLIES 6
matkvaid
Helper III
Helper III

So if i create calculated table with TOPN, i get what i would like to, but then my calculated table does not recalculate when i apply some filters... 😄 

Still trying to find something out. If i can create calculated table, add one more columnt that just has value top100 and add to matrix, it works. So maybe it is possible with selectcolumns or something like that? I'm stugling with table functions, sorry for many stupid questions

Anonymous
Not applicable

Hi @matkvaid 

If you want to get the product name, you can use the TopN in the visual filter, as shown in the image below

 

vxinruzhumsft_0-1670823301757.png

 

For details, please refer to the following links:

 TOP N Filter in Power BI with Zero DAX Code; Visual Level Filter - RADACAD

However, if you want to display the Topn measure, you can't do it, because TopN returns multiple values and is a table, please refer to the following link for details

 TOPN DAX Function: How it works in Power BI? Comparison against the top group - RADACAD

Best Regards,

 

Yolo Zhu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Hi, yes i can add topn filter, it works 🙂 But the problem is i was aksed to show few levels of top...

Anonymous
Not applicable

Hi @matkvaid 

 

IF you want to display the topn measure like your picture displayed, it cannot, it returns a table

 

Yolo Zhu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

FreemanZ
Super User
Super User

Hi 

@matkvaid 

TOPN returns a table, which is not good for such case. Try to add a index column with RANKX and another column with SWITCH. One column directly shall also be viable.

Helpful resources

Announcements
June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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