Forum Discussion
jochungJE
7 years agoFrequent Visitor
Ranking Column by Supplier Grouping
Hi, I am new to Power BI and I am hoping I can get some help with ranking issue. Thanks in advance for all your help with this question. I have a table that contain supplier score by category an...
- 7 years ago
Hi jochungJE ,
For your requirement, please refer to the formulas below.
Measure = COUNTROWS ( FILTER ( ALL ( new ), ISONORAFTER ( new[sum of score], SELECTEDVALUE ( new[sum of score] ), DESC, new[Supplier], SELECTEDVALUE ( new[Supplier] ), DESC ) ) ) Measure 2 = RANKX(ALL(new),[Measure],,DESC,Dense)Here is the output.
More details, please refer to my attachment.
Best Regards,
Cherry
v-piga-msft
Resident Rockstar
7 years agoHi jochungJE ,
For your requirement, please refer to the formulas below.
Measure =
COUNTROWS (
FILTER (
ALL ( new ),
ISONORAFTER (
new[sum of score], SELECTEDVALUE ( new[sum of score] ), DESC,
new[Supplier], SELECTEDVALUE ( new[Supplier] ), DESC
)
)
)
Measure 2 = RANKX(ALL(new),[Measure],,DESC,Dense)
Here is the output.
More details, please refer to my attachment.
Best Regards,
Cherry
jochungJE
7 years agoFrequent Visitor
Thank you v-piga-msft ,
I need to modify both the Measure and Measure2 to include Period Key in the 'filter grouping'. Once I apply the new condition, the ranking is exactly what I needed.
Thank you so much for your support.
Measure =
COUNTROWS (
FILTER (
ALL ( new ),
ISONORAFTER (
new[sum of score], SELECTEDVALUE ( new[sum of score] ), DESC,
new[Supplier], SELECTEDVALUE ( new[Supplier] ), DESC,
new[Period Key], SELECTEDVALUE(new[Period Key]),DESC
)
)
)
Measure 2 = RANKX(
ALLEXCEPT(new,new[Period Key]),
[Measure],
,
DESC,
Dense
)