Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi all,
When I use the filter Top 5 for a table it can happen that I get 7 or more rows because of equal values. But After 5 Rows I want a cut. Example:
Company Values
AB 40
CB 35
DE 30
DS 20
FR 10
--------------------------------------
GH 10
ST 10
I tried RANKX to get an Index 1,2,3,4,5 and filter that but seems not to be so easy 😕
Solved! Go to Solution.
Hi @Pikachu-Power ,
We can create an auxiliary column to meet your requirement.
1. Create a column to distinguish the same value.
sort condition = RANKX('Table','Table'[Company],,ASC,Dense) * 0.0001 + 'Table'[Values]
2. Then we can use the column to get the top 5 value. Filter the company’s Top N and put the [sort condition] column in By value.
BTW, pbix as attached.
Best regards,
Community Support Team _ zhenbw
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Pikachu-Power ,
We can create an auxiliary column to meet your requirement.
1. Create a column to distinguish the same value.
sort condition = RANKX('Table','Table'[Company],,ASC,Dense) * 0.0001 + 'Table'[Values]
2. Then we can use the column to get the top 5 value. Filter the company’s Top N and put the [sort condition] column in By value.
BTW, pbix as attached.
Best regards,
Community Support Team _ zhenbw
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Refer: https://forum.enterprisedna.co/t/rank-unique-ranking-when-there-are-duplicate-values/2815/6
Check 6 Jun for tie breaker
Also these links
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns
https://radacad.com/how-to-use-rankx-in-dax-part-3-of-3-the-finale
Thats what I find and tried at first 😕 I have no dates like radacat and no index like enterprisedna. and duplicates values dont work in my case. no other way?
I think that duplicates values dont work in my case because i have have date instead of value and use
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
94 | |
81 | |
66 | |
58 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |