Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago

Rank Percentage in Power BI

Hi,

 

I have a question regarding the ranking of Percentage. I have the following table:

GoodsManagerPercentage
BedManager 194.87%
TableManager 294.79%
TableManager 382%
ChairManager 179%

 

I need another column showing the rankings. In the sense, it should look like the following:

GoodsManagerPercentageRanking
BedManager 194.87%1
TableManager 294.79%2
TableManager 382%3
    

I tried my best,  but nothing was just happening. It shows all rankings as "1". I calculated the percentages with the help of a measure. The measure is: Percentage = 'Main Data'[Net Sales]/[Gross Sales]. 

6 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi, I dont know how the digits have got shifted. Its Actually |Manager 1|  |94.87%|

                                                                                                    |Manager 2||  |94.79%|

     

    and so on....

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous ,

    Please try like this:

    Ranking = RANKX(SUMMARIZE(ALLSELECTED('Table'),'Table'[Goods],'Table'[Manager]),[Percentage],,ASC,Dense)

    If this doesn't work, please consider releasing a pbix file without private data, that would be helpful, thanks.
    How to provide sample data in the Power BI Forum

    Best Regards,
    Gao

    Community Support Team

     

    If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
    If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

    How to get your questions answered quickly --  How to provide sample data in the Power BI Forum