Forum Discussion
Jim123456789jim
8 years agoFrequent Visitor
DAX Rank()
Hi All, I have created a table report with columns coming from Excel. Player Matches Avg StrikeRate Runs Rohit 102 34 135 4500 Paul 112 32 1...
Phil_Seamark
8 years agoMicrosoft Employee
If you would like it to respect filter settings it needs to be a calculated measure.
Please try adding the following and adding to a Grid or Matrix
Measure = 1+CALCULATE(
COUNTROWS('Table'),
FILTER(
ALLSELECTED('Table'),
'Table'[Runs]<MAX('Table'[Runs])
)
)Phil_Seamark
8 years agoMicrosoft Employee
Actuall, I see what you are after. I will post the calculation in an hour. I just have to head out the door. :)
- Zubair_Muhammad8 years agoCommunity Champion
Try this as a calculated column
RANK = IF ( Batsmen[Criteria] = 1, RANKX ( FILTER ( Batsmen, Batsmen[Criteria] = 1 ), [Runs],, DESC, DENSE ) )- Zubair_Muhammad8 years agoCommunity Champion
As a Measure
RANK Measure = IF ( SELECTEDVALUE ( Batsmen[Criteria] ) = 1, RANKX ( FILTER ( ALLSELECTED ( Batsmen ), Batsmen[Criteria] = 1 ), CALCULATE ( MAX ( Batsmen[Runs] ) ), , DESC, DENSE ) )
- Phil_Seamark8 years agoMicrosoft Employee
I belive this is what you are after. This is a calculated column
My Rank = CALCULATE( COUNTROWS('Table') , FILTER( 'Table', EARLIER('Table'[Runs]) > 3000 && EARLIER('Table'[Avg]) > 30 && EARLIER('Table'[Matches]) > 100 && EARLIER('Table'[StrikeRate]) > 130), 'Table'[Runs] <= EARLIER('Table'[Runs]) )