Forum Discussion

yforti's avatar
yforti
Icon for Helper II rankHelper II
5 years ago

Duplicate rankx values

Hi guys!

 

I'm having trouble creating a simple RankX measure, as I see that the formula does not contain any type of error, however, the rankx is not working.

I'm trying to rank by establishment (first column), an establishment is a hospital name and is formatted as text.

 

measures used:

Valor Alerta = CALCULATE(SUMX('visao_etapa_conta - Não Remetidas','visao_etapa_conta - Não Remetidas'[VL_CONTA]))
Rank Valor = RANKx(ALL('visao_etapa_conta - Não Remetidas'[ESTABELECIMENTO]),[Valor Alerta],,DESC)
 
 

 

 

9 Replies

  • Hi, yforti 

    Please try using ALLSELECT, instead of ALL.

    Or, if it is OK with you, please share your sample pbix file, then I can try to come up with a more accurate solution.

    Thank you.

    Hi, My name is Jihwan Kim.

    If this post helps, then please consider accept it as the solution to help other members find it faster.

      • Jihwan_Kim's avatar
        Jihwan_Kim
        Icon for Super User rankSuper User

        Hi,

        you can save your file in Onedrive or Googledrive, and you can share the link here.

         

  • Hi,

    Do these measures work?

    Valor Alerta = SUM('visao_etapa_conta - Não Remetidas'[VL_CONTA])
    Rank Valor = RANKx(ALL('visao_etapa_conta - Não Remetidas'[ESTABELECIMENTO]),[Valor Alerta],,DESC)
    If not, then share the download link of your PBI file.