Forum Discussion
MrVillareal
7 years agoRegular Visitor
RANKX in Table Matrix
Hi please your help with RANKX function. I created this measure:
Rank Segment Sales =
IF(NOT(ISBLANK([Sum of Net Sales])),
RANKX(
ALL('Profit Centers'[Segment Name]),
[Sum of Net Sales]
)
)
Now I created 2 matrix tables,
A. 1st Table with Segment name, Rank Segment Sales, and Sum of Net Sales
B. 2nd Table with Rank Segment Sales and Sum of Net Sales
But when I clicked the 1st Table for the Rank 1 Segment Name, the 2nd Table is filtered but shows Rank 2 for the same Segment Name.
Now I created 2 matrix tables,
A. 1st Table with Segment name, Rank Segment Sales, and Sum of Net Sales
B. 2nd Table with Rank Segment Sales and Sum of Net Sales
But when I clicked the 1st Table for the Rank 1 Segment Name, the 2nd Table is filtered but shows Rank 2 for the same Segment Name.
Any idea what is the problem?
Thanks in advance.
Regards,
Marvin
I found the solution:
https://www.sqlbi.com/blog/marco/2014/07/16/use-of-rankx-with-decimal-numbers-in-dax/
My workaround is to use ROUND function in my measure [Sum of Net Sales].
1 Reply
- MrVillarealRegular Visitor
I found the solution:
https://www.sqlbi.com/blog/marco/2014/07/16/use-of-rankx-with-decimal-numbers-in-dax/
My workaround is to use ROUND function in my measure [Sum of Net Sales].