Forum Discussion
Top 5 in Rows and Columns
- 6 years ago
Anonymous - Try replacing your ALL statements with ALLSELECTED. ALLSELECTED is kind of tricky but it might work for you. But, the issue is almost certainly your ALL statements.
Anonymous - Try replacing your ALL statements with ALLSELECTED. ALLSELECTED is kind of tricky but it might work for you. But, the issue is almost certainly your ALL statements.
Hi Greg_Deckler
Thank you so much for your suggestion. I replaced All with All selected and now able to get the results.
The only change I have done here is that I am only fetching divsion from DAX Top 5 associate names are filtering out through powerbi Top N Filter option and for Category I am filtering through page level filter.
But its works and giving the correct output.
Below Is the query which I perfromed.
VAR __division =
RANKX (
SelectedALL ( 'Table'[Division] ),
CALCULATE(
[spend],
ALLEXCEPT( 'Table', 'Table'[Division] ) ),
,
DESC,
DENSE
) <= __topN
RETURN
IF( __division && __associate, [spend] )
Really appreciate
Regards
Uphar Tandon