Maha1991
New Member
0
I have a major headache now. My client wants Global Ranking and it should not be changed if he make any slicer selection. Below are the issues which I'm facing
Rank =
Var summry=
SUMMARIZE(**ALLSELECTED**('Employee'),
'Employee'[Employee Name],
"TotalScore",[Total Score],
"WinRate",[Win Rate],
"CustomerCount",[Customer Count])
var tmp= ------- Here I'm doing Tie Breaker based on Win Rate & CustomerCount
ADDCOLUMNS(summry,"RNK",
RANKX(summry,
RANKX(summry,
RANKX (summry, [TotalScore])
+ DIVIDE(
RANKX(summry, [WinRate],,ASC),
(COUNTROWS(summry) + 1)
)
, , DESC) +
+ DIVIDE(
RANKX(summry,[CustomerCount],,ASC),
(COUNTROWS(summry) + 1)
)
, , ASC)
)
var rnk = MAXX(FILTER(tmp,'Employee'[Employee Name]=SELECTEDVALUE('Employee'[Employee Name])),[RNK])
return rnk
In the image, you can see it missing many ranks if I use ALL function as it Ranking all data and not filtered data.
Please provide a solution for this
I have a major headache now. My client wants Global Ranking and it should not be changed if he make any slicer selection. Below are the issues which I'm facing
- I used ALL Function - Got Static Ranking but the problem is my table data is a filtered data based on visual and page filters. But this filters are omitted by All Function and it ranks all the data
- I used ALLSELECTED Function - It Ranks based on my filtered data but the Ranking is not static and it is dynamic
- My issue is My Rank should be based on my filtered data in my data table and also it should be static and should not be affected by slicer.
Rank =
Var summry=
SUMMARIZE(**ALLSELECTED**('Employee'),
'Employee'[Employee Name],
"TotalScore",[Total Score],
"WinRate",[Win Rate],
"CustomerCount",[Customer Count])
var tmp= ------- Here I'm doing Tie Breaker based on Win Rate & CustomerCount
ADDCOLUMNS(summry,"RNK",
RANKX(summry,
RANKX(summry,
RANKX (summry, [TotalScore])
+ DIVIDE(
RANKX(summry, [WinRate],,ASC),
(COUNTROWS(summry) + 1)
)
, , DESC) +
+ DIVIDE(
RANKX(summry,[CustomerCount],,ASC),
(COUNTROWS(summry) + 1)
)
, , ASC)
)
var rnk = MAXX(FILTER(tmp,'Employee'[Employee Name]=SELECTEDVALUE('Employee'[Employee Name])),[RNK])
return rnk
In the image, you can see it missing many ranks if I use ALL function as it Ranking all data and not filtered data.
Please provide a solution for this