Forum Discussion
rampsaladi
8 years agoFrequent Visitor
Dynamic Rank per Product in Time Period
Hi I need to be help create a Rank column. I need to be able to generate the rank in the context of the Time Period for the Products based on the Amount and This rank will be in the context of t...
Zubair_Muhammad
8 years agoCommunity Champion
GIve this MEASURE a shot as well
RANK =
RANKX (
FILTER (
ALLSELECTED ( Table1 ),
Table1[Time Period] = SELECTEDVALUE ( Table1[Time Period] )
),
CALCULATE ( SUM ( Table1[Amt] ) ),
,
DESC,
DENSE
)
Zubair_Muhammad
8 years agoCommunity Champion
Infact this one should give the proper results with slicers
RANK =
RANKX (
CALCULATETABLE (
VALUES ( Table1[Product] ),
FILTER (
ALLSELECTED ( Table1 ),
Table1[Time Period] = SELECTEDVALUE ( Table1[Time Period] )
)
),
CALCULATE ( SUM ( Table1[Amt] ) ),
,
DESC,
DENSE
)
- rampsaladi8 years agoFrequent Visitor
Thank you for providing the information but the DAX you provided does not give me the correct result, it always gives rank as 1
- Zubair_Muhammad8 years agoCommunity Champion
- rampsaladi8 years agoFrequent Visitor
yes I can see that but It does not work when I do it but let me try again. I also have another requirement where I need to be able to display the Rank for each time period side by side and I tried to do that by filterting the data for the specific time period but it did not work. Any help is appreciated.
Basically I need to show a side by side comparison of the Product Rank over time period in a specific market