Forum Discussion
Rankx based on table column
- 5 years ago
Dunner2020 - See this article - https://community.powerbi.com/t5/Quick-Measures-Gallery/To-Bleep-with-RANKX/m-p/1042520#M452
Dunner2020 - See this article - https://community.powerbi.com/t5/Quick-Measures-Gallery/To-Bleep-with-RANKX/m-p/1042520#M452
- Dunner20205 years agoPost Prodigy
Greg_Deckler , I followed the article and changed my code to the following:
ICP Rank = RANKX( ALL('Table'),[ICP],,DESC)But it still gave me an error that 'The value for ICP cannot be determined. Either the column does not exist, or there is no current row for this column'.- Greg_Deckler5 years agoCommunity Champion
Dunner2020 - You need an aggregator around it like SUM, MAX, etc.
- amitchandak5 years agoSuper User
Dunner2020 , Are trying Column Rank (Static) or measure Rank( Dynamic and Context sensitive.
New column
ICP Rank = RANKX( ALL('Table'),[ICP],,DESC)
New Measure
ICP Rank = RANKX( ALL('Table'),Calculate(Sum([ICP])),,DESC)
or
ICP Rank = RANKX( ALL('Table'[Customer]),Calculate(Sum([ICP])),,DESC)
ICP Rank = RANKX( ALLSELECTED('Table'[Customer]),Calculate(Sum([ICP])),,DESC)
For Rank Refer these links
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns
https://radacad.com/how-to-use-rankx-in-dax-part-3-of-3-the-finale
https://community.powerbi.com/t5/Community-Blog/Dynamic-TopN-made-easy-with-What-If-Parameter/ba-p/367415