Forum Discussion
Rankx producing incorrect order
Anonymous , are you viewing it for Cancellation reason?
Then try like
Custom Col Cancellation Ranks =
Var RankByCancellation=
RANKX(
All(MyPT_Cancellations[Cancellation reason]), // or use allselected in place of all
CALCULATE(
COUNT(MyPT_Cancellations[No. of Clients]),
ALLEXCEPT(MyPT_Cancellations,MyPT_Cancellations[Cancellation reason])
),
,
DESC,
Dense
)
Return
IF(RankByCancellation<=9,RankByCancellation,10)
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
Hi amitchandak
Sorry, i tried Allselected but doesnt changed anything. Let me share table format and output
- amitchandak5 years agoSuper User
Anonymous , have tried with
All(MyPT_Cancellations[Cancellation reason])
Allselected(MyPT_Cancellations[Cancellation reason])
- Anonymous5 years agoNot applicable
- Anonymous5 years agoNot applicable
Please guide how can remove dense rank and give separate rank if the value is same for the cancellation reason, I am doing top 19 + 20 (Other)
So, in this case rather than having 12 rank for more than 1 record I want serial rank no matter if the values are same.
I tried removing dense but the result show 1 and then 20 for all
- amitchandak5 years agoSuper User
Anonymous ,Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.