Forum Discussion
Ruedi007
6 years agoFrequent Visitor
RankX - Value cannot be determined Either the column does not exist or there is no current row
I try to use rankx on my dataset that is State Inhabitants City California 3792621 Los Angeles Texas 2325502 Housten Texas 1345047 Dallas California 1301617 San Diego ...
- 6 years ago
Hi Ruedi007
Use this one:
Measure 3 = rankx(ALLSELECTED(Sheet1),FIRSTNONBLANK(Sheet1[Inhabitants],[Inhabitants]),,ASC)Or this one:
Measure 3 = rankx(ALLSELECTED(Sheet1),CALCULATE(SUM(Sheet1[Inhabitants])))and have a read of this blog on using RANKX in measures http://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
lbendlin
Super User
6 years agomake sure that Inhabitants is actually a number and not a text. Also, it is advisable to use measures instead, such as
i := sum(sheet1[inhabitants])
Measure: = rankx(ALLSELECTED(Sheet1), i)