Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello All,
Any help would be greatly appreciated.
Example table...
Table1
Code Date Sales$
AA 12/10/2018 200.00
BB 11/10/2018 200.00
AA 10/10/2018 200.00
CC 12/10/2018 200.00
DD 14/10/2018 200.00
FF 15/10/2018 200.00
FF 17/10/2018 200.00
AA 18/10/2018 200.00
I want to create a specifc ,measure to return me the rank of the string AA amongst the above sales.
I dont wish to have a table to collate totals for other reason.
The idea will be to have five seperate Measures that store the rank for AA BB CC DD FF.
These will be represented in cards on the report - I dont want to have to set Visual filters on each card.
is there a way in the RANKX statment where I can specify the text to rank.
ie What rank is Code "AA" in Table1.Code field for Sum(Sales$)
I have done rank statements before but they have always been for column names and been able to use for any code in the table.
In this example I wish to fix the Code and seek a rank for it.
Any suggestions welcome and help appreciated in advance.
Solved! Go to Solution.
HI @shaunwilks
Try this MEASURE pattern
Measure = CALCULATE ( RANKX ( ALL ( TableName[Code] ), CALCULATE ( SUM ( TableName[Sales$] ) ) ), TableName[Code] = "AA" )
HI @shaunwilks
Try this MEASURE pattern
Measure = CALCULATE ( RANKX ( ALL ( TableName[Code] ), CALCULATE ( SUM ( TableName[Sales$] ) ) ), TableName[Code] = "AA" )
Thanks very much - my production report was somewhat more complicated but the suggested formula you provided was a big help.
I find myself comfortable with most DAX function but the RANKX one totally consfuses me.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
105 | |
105 | |
88 | |
73 | |
66 |
User | Count |
---|---|
124 | |
113 | |
98 | |
80 | |
72 |