Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Ethanhunt123
Helper III
Helper III

Mayor cantidad por persona

Tengo una tabla que tiene muchas columnas. (fecha, Usuario, Importe, etc.). Necesito encontrar al usuario que tiene la mayor cantidad independientemente de cualquier otra columna (fecha, etc.).

La salida será GHI y 1000

NombreCantidad
Abc100
Def200
Ghi1000
Jkl350
1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Ethanhunt123 ,

lastnonblankvalue(Table[Amount], max(Table[Name]))

seleccionar con Importe no resumido. De lo contrario, cree un rango y filtre en 1 o use el top 1

ventas á sum(Tabla[Importe])

Rank á RANKX(all(Table[Name]),[Sales])


Rank Top 1- CALCULATE(if([Rank]-,[Sales],BLANK()) ,VALUES(Table[Name]))
Rank Top 1 á sumx(VALUES(Table[Name]),if([Rank]-1,[Sales],BLANK()) )
Top 1 Rank á CALCULATE([Sales],TOPN(1,all(Table[Name]),[Sales],DESC),VALUES(Table[Table]))

Para rango Consulte estos enlaces
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns
https://radacad.com/how-to-use-rankx-in-dax-part-3-of-3-the-finale
https://community.powerbi.com/t5/Community-Blog/Dynamic-TopN-made-easy-with-What-If-Parameter/ba-p/3...
Rango 2o superior á sumx(filter(VALUES(Geography[City]),[Rango de la ciudad]-2),[Ventas] )

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Ethanhunt123 ,

lastnonblankvalue(Table[Amount], max(Table[Name]))

seleccionar con Importe no resumido. De lo contrario, cree un rango y filtre en 1 o use el top 1

ventas á sum(Tabla[Importe])

Rank á RANKX(all(Table[Name]),[Sales])


Rank Top 1- CALCULATE(if([Rank]-,[Sales],BLANK()) ,VALUES(Table[Name]))
Rank Top 1 á sumx(VALUES(Table[Name]),if([Rank]-1,[Sales],BLANK()) )
Top 1 Rank á CALCULATE([Sales],TOPN(1,all(Table[Name]),[Sales],DESC),VALUES(Table[Table]))

Para rango Consulte estos enlaces
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns
https://radacad.com/how-to-use-rankx-in-dax-part-3-of-3-the-finale
https://community.powerbi.com/t5/Community-Blog/Dynamic-TopN-made-easy-with-What-If-Parameter/ba-p/3...
Rango 2o superior á sumx(filter(VALUES(Geography[City]),[Rango de la ciudad]-2),[Ventas] )

How it will handle the situation when 2 rows have same amount

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.