Forum Discussion
RANKX Not working as expected
Hi,
I have a table which is sorted in desc order by a basic DIVIDE measure in the column called '% Space in Backlog' (see below)
You can see that many of the '% Space in Backlog' are 100% but it does start to go down after that.
The RANKX I've done is as follows:
- Anonymous6 years ago
Hi LOGiT,
You can try to use below measure if it suitable for your requirement:
Ranktest = RANKX(ALLSELECTED(V_POWERBI_DATASET),[T1CB divided by EstTreatCost],,DESC,Dense)
I create a table with some sample data to test.
SalPct = DIVIDE(SUM('Brand Rank'[Sales1]),SUM('Brand Rank'[Sales2])) CalPct = CALCULATE([SalPct]) RankTest = RANKX(ALLSELECTED('Brand Rank'),[CalPct],,DESC,Dense)If above not help. it will be help if you share some sample data and [T1CB divided by EstTreatCost] measure formula for test.
Best Regards,
Jack Chen
2 Replies
- JosefPrakljacicSolution Sage
Hey LOGiT ,
try RANKX(ALL(V_POWERBI_DATASET),CALCULATE([T1CB divided by EstTreatCost]))
If this is not working would you mind to share some sample data so that we can try it out by ourselves.
If this post was helpful may I ask you to mark it as solution and give it some kudos?
Have a nice day!
BR,
Josef - AnonymousNot applicable
Hi LOGiT,
You can try to use below measure if it suitable for your requirement:
Ranktest = RANKX(ALLSELECTED(V_POWERBI_DATASET),[T1CB divided by EstTreatCost],,DESC,Dense)
I create a table with some sample data to test.
SalPct = DIVIDE(SUM('Brand Rank'[Sales1]),SUM('Brand Rank'[Sales2])) CalPct = CALCULATE([SalPct]) RankTest = RANKX(ALLSELECTED('Brand Rank'),[CalPct],,DESC,Dense)If above not help. it will be help if you share some sample data and [T1CB divided by EstTreatCost] measure formula for test.
Best Regards,
Jack Chen