Forum Discussion
mazingazeta
5 years agoNew Member
Help with DAX Measure (LOOKUPVALUE, TOPN, RANKX; MAX, Groupby)
Hello, I have the following question: I need the NAME of the Agent with the most amount per Customer. (the result should be : a - Hannes, b - fritz, c - mike). I tried and thinked a lot of different ...
- 5 years ago
You can use these measures:
_TotalAgent = SUMX(SUMMARIZE('Table', 'Table'[Agent], "Total", SUM('Table'[Amount])), [Total]) _Rank = IF(HASONEVALUE('Table'[Agent]), RANKX(ALL('Table'[Agent]), [_TotalAgent],,DESC), BLANK())
camargos88
5 years agoCommunity Champion
You can use these measures:
_TotalAgent = SUMX(SUMMARIZE('Table', 'Table'[Agent], "Total", SUM('Table'[Amount])), [Total])
_Rank = IF(HASONEVALUE('Table'[Agent]), RANKX(ALL('Table'[Agent]), [_TotalAgent],,DESC), BLANK())