Forum Discussion
gtamir
Post Patron
7 years agoHow can I create a simple index column with dax.
I want to create a simple index column starting with 1 next to the total column. I can't do it with query editor because it is a calculated table. Giora
Greg_Deckler
Community Champion
6 years agogtamir - Oh, then you want my SuperRank column formula, which I just invented:
SuperRank =
VAR __table = FILTER(ALL('Table6'),[Total] > EARLIER('Table6'[Total]))
VAR __tableSame = FILTER(ALL('Table6'),[Total] = EARLIER('Table6'[Total]) && [Customer] < EARLIER(Table6[Customer]))
RETURN
COUNTROWS(__table) + 1 + COUNTROWS(__tableSame)
Attaching PBIX, you want Table6.
gtamir
Post Patron
6 years agoThank you for the quick response. I'll try it and try to understand..
I'll let you know.