Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hola,
Necesito realizar un ranking, y no logro hacerlo.
Tengo distintas columnas como medidas, es decir tengo una columna para Ventas 1, otra columna para Ventas 2 y otra para Ventas 3. Además tengo una columna que me indica las clasificaciones (A,B,C) para cada Venta, quedando algo así:
A B C
Venta 1 10 20 90
Venta 2 40 80 60
Venta 3 70 50 30
Total 120 150 180
El ranking necesito realizarlo en base al total de cada clasificación. Quedando así el ranking:
A B C
Venta 1 3 3 1
Venta 2 2 1 2
Venta 3 1 2 3
Muchas gracias!
Solved! Go to Solution.
Hi Paula,
To achieve your requirement, create a calculate column using DAX as below:
Rank = RANKX(FILTER(Table1, Table1[Category] = EARLIER(Table1[Category])), RANKX(ALL(Table1), Table1[Value]), , ASC, Dense)
You can also refer to PBIX file here: https://www.dropbox.com/s/xl0kr9grzl9gg9l/RANKX%20DAX%20-%20Columnas%20y%20Filas.pbix?dl=0.
Best Regards,
Jimmy Tao
Hi Paula,
To achieve your requirement, create a calculate column using DAX as below:
Rank = RANKX(FILTER(Table1, Table1[Category] = EARLIER(Table1[Category])), RANKX(ALL(Table1), Table1[Value]), , ASC, Dense)
You can also refer to PBIX file here: https://www.dropbox.com/s/xl0kr9grzl9gg9l/RANKX%20DAX%20-%20Columnas%20y%20Filas.pbix?dl=0.
Best Regards,
Jimmy Tao
Muchas Gracias! @v-yuta-msft
Me podrías ayudar con esto?:
Ahora necesito realizar un ranking pero de manera horizontal, por ejemplo sobre las Ventas 1. Pero esta vez necesito que se realice el ranking solo sobre A y C, quedando los ranking: C= 1° y A= 2°, sin tener que eliminar de la base a la categoria D.
Saludos!
User | Count |
---|---|
128 | |
109 | |
100 | |
65 | |
62 |
User | Count |
---|---|
137 | |
115 | |
102 | |
71 | |
61 |