Get certified in Microsoft Fabric—for free! For a limited time, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now
Hello all,
I tried to create RANKX based on the category to present the highest rank for specific Title. But the outcome for my rankx was 1 in each row.
rankCategory = RANKX(ALL(Table[Category]), Value)
Sample of the data used
Title | Category | Value | other columns |
A | ABC | 15 | ... |
B | ABC | 16 | ... |
C | ABC | 20 | ... |
D | ABC | 84 | ... |
E | CDE | 1 | ... |
F | EFG | 34 | ... |
G | EFG | 54 | ... |
H | EFG | 14 | ... |
I | HIJ | 25 | ... |
J | HIJ | 64 | ... |
K | ZZ | 12 | ... |
L | ZZ | 25 | ... |
Desired outcome
Title | Category | RANK | Value | other columns |
A | ABC | 4 | 15 | ... |
B | ABC | 3 | 16 | ... |
C | ABC | 2 | 20 | ... |
D | ABC | 1 | 84 | ... |
E | CDE | 1 | 1 | ... |
F | EFG | 2 | 34 | ... |
G | EFG | 1 | 54 | ... |
H | EFG | 3 | 14 | ... |
I | HIJ | 2 | 25 | ... |
J | HIJ | 1 | 64 | ... |
K | ZZ | 2 | 12 | ... |
L | ZZ | 1 | 25 | ... |
Solved! Go to Solution.
Hi,
Try this formula :
Rank = RANKX(CALCULATETABLE(Table,ALLEXCEPT(Table,Table[Category])),Table[Value],,DESC)
Hi,
Try this formula :
Rank = RANKX(CALCULATETABLE(Table,ALLEXCEPT(Table,Table[Category])),Table[Value],,DESC)
User | Count |
---|---|
115 | |
95 | |
87 | |
76 | |
65 |
User | Count |
---|---|
138 | |
113 | |
110 | |
98 | |
93 |