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
salman_ali
Helper IV
Helper IV

Problema con los totales

Hola equipo, este es el problema que estoy teniendo
Aquí abajo está mi consulta
km/parada ?
VAR AVGKMS - PROMEDIO(E3table_1[KM])
devolución
if(hasonevalue(E3table_1[ManInd]),AVGKMS,SUMX(VALUES(E3table_1[ManInd]),AVGKMS))
la salida que estoy recibiendo es
Manifiesto total n.o 4
Medio Km/desplazamiento 320,86
Conteo 43
Total medio KM/Shift (AVGKMS)- 1.283,43
Lo siento no puedo imprimir la pantalla, ya que es demasiado pequeño.
A continuación es lo que quiero ver (Esto a continuación es cuando hice esto en Excel)
Como se puede ver a continuación
mi 4 filas en el manifiesto es correcto como arriba
mis recuentos totales de 43 también son correctos,
mi promedio de KMS también es correcto.
Etiquetas de filaPromedio de KMRecuento de paradas
4583383350.8361211
4623383408.772369
4633383347.6174410
4643383214.0422213
Grand Total320.857484243
suma 4 avg kms1321.26814
suma dividida por recuento30.72716605

La discrepancia es que cuando corro por encima de la fórmula dax quiero que la suma sea 1321.268 como se muestra a continuación, pero está llegando a 1.283.43, y no tengo idea de dónde lo estoy obteniendo. ¿alguien puede ayudar?
1 ACCEPTED SOLUTION

@salman_ali estas serán dos medidas diferentes, una Medida de Kms Promedio y la 2a será Medida1

AVG Kms Measure = AVERAGE(E3table_1[KM])

Measure1 = 
IF ( HASONEVALUE(E3table_1[ManInd]),
[AVG Kms Measure],
SUMX(
SUMMARIZE ( VALUES(E3table_1[ManInd]), E3table_1[ManInd], "AvgKms",[AVG Kms Measure] ),
[AvgKms]
)
)



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

View solution in original post

9 REPLIES 9
v-frfei-msft
Community Support
Community Support

Hola @salman_ali ,

Puede copiar y pegar sus datos de muestra aquí directamente. Por favor, comparta sus datos de muestra y el resultado excepto para mí si no tiene ninguna Información Confidencial. Cargue sus archivos en One Drive for Business y comparta el enlace aquí.

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.
Ashish_Mathur
Super User
Super User

Hola

¿Funcionan estas medidas?

AVGKMS - PROMEDIO(E3table_1[KM])

Measure1 á if(hasonevalue(E3table_1[ManInd]),AVGKMS,SUMX(SUMMARIZE(VALUES(E3table_1[ManInd]),E3table_1[ManInd],"ABCD",[AVGKMS]),[ABCD]))

Espero que esto ayude.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Lo siento Ashish, esto me está dando error

Hola

¿Funciona esto?

AVGKMS - PROMEDIO(E3table_1[KM])

Measure1 á if(hasonevalue(E3table_1[ManInd]),[AVGKMS],SUMX(SUMMARIZE(VALUES(E3table_1[ManInd]),E3table_1[ManInd],"ABCD",[AVGKMS]),[ABCD]))

Si no es así, comparta el enlace desde donde puedo descargar el archivo PBI y mostrar claramente el objeto visual donde mi medida no funciona.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Lo siento por desgracia no puedo compartir el archivo, pero el error viene cuando i tipo Measure1 .

¿tiene que haber algo después de

AVGKMS - AVERAGE(E3table_1[KM]) para conectar las dos líneas?

Hola

Lo siento, pero no puedo ayudar si no puede compartir ningún dato.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Entiendo, gracias

@salman_ali estas serán dos medidas diferentes, una Medida de Kms Promedio y la 2a será Medida1

AVG Kms Measure = AVERAGE(E3table_1[KM])

Measure1 = 
IF ( HASONEVALUE(E3table_1[ManInd]),
[AVG Kms Measure],
SUMX(
SUMMARIZE ( VALUES(E3table_1[ManInd]), E3table_1[ManInd], "AvgKms",[AVG Kms Measure] ),
[AvgKms]
)
)



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Gracias, esto funcionó

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.