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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
spompeo
New Member

RANKX Player Position Rank over Time

Farily new with DAX and struggling with filtered RANKX. I have a StatsDB table and a playerkey table for a fantasy football database I'm working on.

 

Each row of the data table is a game log for a player:

 

StatsDB:

  • PlayerID (relation)
  • Year
  • Name
  • Position
  • Team
  • Week
  • Pass Attempts
  • Pass Completions
  • etc. - Other relevant offense statistics. 

PlayerKey

  • PlayerID (relation)
  • Player Name
  • Current Position

I created measures that calculate fantasy points based on stats. 

 

Example Measures:

  • FPTS Rush Yds:=CALCULATE(sum([Rush Yards])*.1)
  • FPTS Total:=[FPTS Fumb Lost]+[FPTS Rush Yds]+[FPTS Pass TDs]+ etc.

 

I have a points rank that seems to work for the context of the pivot / slicers - 

  • FPTS Rank:=if(not(ISBLANK([FPTS Total])),rankx(filter(all(PlayerKey),not(isblank([FPTS Total]))),[FPTS Total]),blank())

 

However, my goal is to have a "fantasy points positional rank" measure. Where did a player rank in fantasy points scored at his position over any given period of time?

 

Any ideas how to go about this? Would be much appreciated! I can do this manually but am trying to work positional ranks into the data model and am stuck.

1 REPLY 1
v-frfei-msft
Community Support
Community Support

Hi @spompeo ,

 

Could you please share your sample data and excepted result to me if you don't have any Confidential Information. Please upload your files to One Drive and share the link here.

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors