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

Get Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.

Reply
Shelley
Post Prodigy
Post Prodigy

RANKX Works Halfway

Hi All, I'm using RankX to rank distributors by orders. When I show a table with the list, it works as expected. However, I am working on a dashboard and want to filter on a distributor, and see their rank among the total. When I do this, it doesn't work. It always shows 1 of 1. What the heck am I missing?

 

Here's the formula: 

Rank Core Orders $ = RANKX(ALL('Link Table'[Distributor APR]), [Total Core Orders $], , DESC)

 

[The link table contains all distributors and is used to link all the fact tables together on that one distributor key.]

 

I'm trying to show the distributor is ranked X out of Y:

APR Rank Text = [Rank Core Orders $] & " of " & [APR Count]

 

Displays properly with NO slicer selections AND in table format:

Distributor   Order $     Rank

A                   $500           1

B                    $450          2

C                    $300          3

D                   $299           4

 

 

Card showing Rank shows 1 of 115, when nothing is selected. (I'd rather have it be blank.)

 

But when I click a slicer to select one distributor:

Everything in the table goes away except the distributor selected.

In addition, the Card showing the rank, now shows 1 of 1. I thought the ALL in the formula would prevent this behavior?

Rank Core Orders $ = RANKX(ALL('Link Table'[Distributor APR]), [Total Core Orders $], , DESC)

 

What am I missing? Any help is appreciated. Thank you!

1 REPLY 1
Greg_Deckler
Community Champion
Community Champion

Try not referencing your column:

 

Rank Core Orders $ = RANKX(ALL('Table6'), [Order $], , DESC)


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

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.