Forum Discussion
Anonymous
8 years agoNot applicable
RANKX ISSUES
I have been trying to iron out this issue for a week now. I saw in tutorials that if you use ALL in your RANKX formula that the Rank result would not be "Ones". I have done so in the below example ...
- 8 years ago
Anonymous
Or with this
Ranking = RANKX ( SUMMARIZE ( ALLSELECTED ( 'WMGBU BEx Query' ), 'WMGBU BEx Query'[ENT BASE ITEM], 'WMGBU BEx Query'[profit center] ), CALCULATE ( SUM ( 'WMGBU BEx Query'[DIRECT MARGIN (PROJECTED)] ) ) / CALCULATE ( SUM ( 'WMGBU BEx Query'[REVENUE (PROJECTED)] ) ) )
Anonymous
8 years agoNot applicable
Alas this tells me everything that I have completed already. I have the rank appearing correctly now...my issue is if I want to add a profit center to the table (not a filter) the rank changes to by profit center as well. I need the rank regardless of the profit center which this thread does not address.
Zubair_Muhammad
Community Champion
8 years agoAnonymous
Try with
Ranking =
RANKX (
ALL ( 'WMGBU BEx Query'[ENT BASE ITEM], 'WMGBU BEx Query'[profit center] ),
CALCULATE ( SUM ( 'WMGBU BEx Query'[DIRECT MARGIN (PROJECTED)] ) )
/ CALCULATE ( SUM ( 'WMGBU BEx Query'[REVENUE (PROJECTED)] ) )
)- Zubair_Muhammad8 years ago
Community Champion
Anonymous
Or with this
Ranking = RANKX ( SUMMARIZE ( ALLSELECTED ( 'WMGBU BEx Query' ), 'WMGBU BEx Query'[ENT BASE ITEM], 'WMGBU BEx Query'[profit center] ), CALCULATE ( SUM ( 'WMGBU BEx Query'[DIRECT MARGIN (PROJECTED)] ) ) / CALCULATE ( SUM ( 'WMGBU BEx Query'[REVENUE (PROJECTED)] ) ) )- Anonymous8 years agoNot applicable
This one worked perfectly...thx so much for your time and efforts!
- Anonymous8 years agoNot applicable
One last question...is there a way to add to this formula that will restrict the results to only the top 10?
Thx
- Zubair_Muhammad8 years ago
Community Champion
Hi
Sorry for late reply. I am out of town actually
You can put the measure in visual filter and select top 10