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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Keep RANKX values static

In my organization we have our stores set up in a hierarchy that goes Region > District > Store. Each level of hierarchy has its own performance scorecard, and each Store/District/Region is ranked based on that score. I currently use this formula to produce a rank at each level:

 

SC Rank = IF(
ISFILTERED(Roster[Store]), RANKX(ALL(Roster[Store]),[SC Total Score]), IF(
ISFILTERED(Roster[District]), RANKX(ALL(Roster[District]),[SC Total Score]), IF(
ISFILTERED(Roster[Region]), RANKX(ALL(Roster[Region]),[SC Total Score]))))
 
This works as I'd expect it to at each level UNTIL a filter is applied. If someone selects to just view a specific District all Stores in that District are re-ranked against just each other rather than still showing their global rank. Is there a way to make it so that BI "remembers" what their global rank is (leave the rank static) rather than globally changing it?
1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

Use a calculated column rather than a measure.  Calculated columns are only refreshed once during data source refresh, and are unaffected by filter changes.

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

lbendlin
Super User
Super User

Use a calculated column rather than a measure.  Calculated columns are only refreshed once during data source refresh, and are unaffected by filter changes.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.