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
Anonymous
Not applicable

Tomar el total de una columna y asignarlo a una fila de la misma columna. Necesita ayuda de DAX

¿Cómo puedo tomar la suma/total de una medida y asignarla a otra fila de esa misma columna?

Déjame explicarte...

Digamos que tengo una tabla con rangos/categorías como:

Filas
IMP0
IMP1
IMP2
IMP3

IMP4

IMP5

Tengo una medida que tiene valores para IMP1-IMP5. Quiero que el TOTAL de IMP1-5 se ponga en IMP0.

FilasImpresiones
IMP0
IMP150
IMP2100
IMP3150
IMP450
IMP550
Total400

RESULTADO FINAL

FilasImpresiones
IMP0400
IMP150
IMP2100
IMP3150
IMP450
IMP550
Total400

la suma de imp1-5 es 400 por lo que 400 se coloca dentro de IMP0.

¿Es esto alcanzable?

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@nataliengarces , Probar como

if(max(Table[IMP0]) á"IMP0", calculate(sum(Table[IMPRESSIONS]), filter(all(Table), Table[IMP0] <> "IMP0")) ,sum(Table[IMPRESSIONS]) )

View solution in original post

2 REPLIES 2
V-pazhen-msft
Community Support
Community Support

@nataliengarces

Supongo que esto es lo que quieres:

Measure = IF(max('Table'[RANKS]) ="IMP0", SUMX(ALL('Table'),[IMPRESSIONS]),[IMPRESSIONS])

sumx measure.JPG


Paul Zheng _ Equipo de apoyo de la comunidad
Si este post ayuda, entonces considera Aceptarlo como la solución para ayudar a los otros miembros a encontrarlo más rápidamente.

amitchandak
Super User
Super User

@nataliengarces , Probar como

if(max(Table[IMP0]) á"IMP0", calculate(sum(Table[IMPRESSIONS]), filter(all(Table), Table[IMP0] <> "IMP0")) ,sum(Table[IMPRESSIONS]) )

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.