The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Dear experts,
I am trying to figure out what is wrong with my dax measure. I don't understand why I am getting 1 for all ranks.
You are removing the filter from the Exposure column but there is also a filter on the Observation column. Try
Ranking measure =
RANKX (
ALL ( 'Safety stats' ),
CALCULATE ( SUM ( 'Safety stats'[Observations] ) )
)
Hmm, that works for me, and notice how the Others row is now getting a value. Use Performance Analyzer to get the code generated for the table and paste it into DAX Studio. That will tell you if any other filters are being applied which might affect the results, and if you execute the query you can compare the results from DAX Studio with Power BI, which should of course be the same
Nothing unusual there. Is it possible to share a PBIX with any confidential information removed ?
One more piece of information I created another table
I used the exposure column from the newly created table. And the ranking started working suddenly. At this point I think it is some kind bug.
as long as its working, thats the main thing.
the other relationship going into the Safety Stats table, is that single direction or bidirectional? if its bidirectional that could be causing an issue
I just deleted all other tables. And it is still not working.
that is really weird
I exported the table to excel and created a new power bi file with that source and It did not work.
I removed some other columns and then it started working.
I'd go for your ALLNOBLANKROW solution.
Thanks for looking into this. I was very confused for a long time.
User | Count |
---|---|
15 | |
12 | |
8 | |
7 | |
7 |
User | Count |
---|---|
24 | |
21 | |
12 | |
10 | |
7 |