Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Is it possible to have the below Rankx formula filtered on specific peer without the rank showing up as 1?
This is the data set for example, with Peer and Monthly Return being the load from external source.Rank of Total Peers QTD and Total Return QTD being the two measures above.
In PowerBI when using the Dax code below to show just the Target QTD Rank which should show 3, it shows 1.
Is there a solution to filter Target and have the rank show as 3?
Thank you!
Solved! Go to Solution.
Hi,
I am not sure how you will present the end result, but please try something like below if it suits your requirement.
Target Rank =
MAXX (
FILTER (
ADDCOLUMNS (
ALLSELECTED ( 'Import to Powerbi'[Peer] ),
"@rank", [Rank of Total Peers QTD]
),
'Import to Powerbi'[Peer] = "Target"
),
[@rank]
)
Hi,
I am not sure how you will present the end result, but please try something like below if it suits your requirement.
Target Rank =
MAXX (
FILTER (
ADDCOLUMNS (
ALLSELECTED ( 'Import to Powerbi'[Peer] ),
"@rank", [Rank of Total Peers QTD]
),
'Import to Powerbi'[Peer] = "Target"
),
[@rank]
)
Hi Jihwan,
That is perfect, giving the correct result! I appreciate it! 🙂
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
11 | |
9 | |
8 | |
8 | |
8 |
User | Count |
---|---|
13 | |
12 | |
11 | |
10 | |
9 |