Forum Discussion
Problem with rankx function
- 7 years ago
Hi badboy66,
Here I update the formula as below.
2_1_Test Ranking_UR_Test 2 = IF(IF(ISBLANK(Gesamtwerte[1_1_1 UR final_Test]),BLANK(),RANKX(ALL(Gesamtwerte),Gesamtwerte[1_1_1 UR final_Test],,ASC,Dense))<>BLANK(),RANKX(ALL(Gesamtwerte),IF(ISBLANK(Gesamtwerte[1_1_1 UR final_Test]),BLANK(),RANKX(ALL(Gesamtwerte),Gesamtwerte[1_1_1 UR final_Test],,ASC,Dense))))
For the measure 2_2_2 ranking_UR increase final_Test, based on my test. I cannot achieve your goal here.
Regards,
Frank
- 7 years ago
Hi badboy66,
Based on my test, we can create a calculated table here. And create relationship between Gesamtwerte and the new table based on ID.
Table 2 = SUMMARIZE(Gesamtwerte,Gesamtwerte[ID],Gesamtwerte[Name])
Then we can create a measure to get the rank correctly.
new rank = IF(ISBLANK([1_2 increase UR_Test]),BLANK(),RANKX(ALL('Table 2'),[1_2 increase UR_Test],,DESC,Dense))For more details, please check the pbix as attached.
https://www.dropbox.com/s/08yu8jmaaod8hnn/Problem%20with%20rankx%20function.pbix?dl=0
Regards,
Frank
Can you post your data in a form that can be copied and pasted?
Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490
I updated my post above and will upload the test data set separately