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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
Anonymous
Not applicable

Totales equivocados

Hola, chicos

Estoy tratando de crear mi propio pronóstico porque se basa en una planificación.

Para ello tengo algunas medidas y algunos datos para ir con él.

Medida para determinar el precio de las horas en un mes determinado:
Planificación: sumx('Pronóstico'; 'Pronóstico'[Horas] * 'Pronóstico'[PriceFC])

Medida para calcular el total acumulado de las horas trabajadas
CumulativeTotal á CALCULATE(Sum(TimeTransactions[AmountFC]); FILTER(ALL(PowerBI_Calendar[Fecha]); PowerBI_Calendar[Fecha] <-Max(PowerBI_Calendar[Fecha])))

Medida para determinar si necesito utilizar las horas trabajadas reales o la planificación:
GuideLine: IF(OR(SUMX(TimeTransactions; TimeTransactions[AmountFC]) á BLANK(); SUMX(TimeTransactions; TimeTransactions[AmountFC]) < [Planificación]); [Planificación]; SUM(TimeTransactions[AmountFC]))

Medir para obtener el total acumulado de mi directriz para que se pueda mostrar muy bien en un gráfico:
Pronóstico acumulado: CALCULATE([GuideLine]; FILTER(ALL(PowerBI_Calendar[Datum]); PowerBI_Calendar[Datum] <-Max(PowerBI_Calendar[Datum])))

El problema radica en el forcast acumulativo, debe ser un número diferente de lo que está mostrando.
¿Alguien sabe lo que estoy haciendo mal?

Datos de muestra

Capture1(1).PNGCapture2.PNGCapture1.PNG

4 REPLIES 4
v-kelly-msft
Community Support
Community Support

Hola @QueenieBarends

Entonces, ¿qué hay en la tabla'TimeTransactions'? ¿Puede mostrarme su archivo .pbix?

Saludos
Kelly
¿Respondí a tu pregunta? ¡Marca mi puesto como solución!

Greg_Deckler
Super User
Super User

Esto parece un problema de totales de medida. Muy común. Vea mi post al respecto aquí: https://community.powerbi.com/t5/DAX-Commands-and-Tips/Dealing-with-Measure-Totals/td-p/63376

Además, esta medida rápida, medida totales, la palabra final debe obtener lo que necesita:
https://community.powerbi.com/t5/Quick-Measures-Gallery/Measure-Totals-The-Final-Word/m-p/547907


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Mastering Power BI 2nd Edition

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Hola @Greg_Deckler ,

He estado probando su solución, pero no estoy seguro de cómo continuar.

Hice esta medida:

MyMeasure2 ?
VAR __table ? SUMMARIZE(TimeTransactions;[ Proyecto];" __value"; [Guía])
devolución
IF(HASONEVALUE(TimeTransactions[Project]); [GuideLine]; SUMX(__table; [__value]))
Pero me da valores aún más extraños
Capture3.PNG
¿Me puedes ayudar?
Saludos
Queenie

Prueba esto:

MyMeasure2 =
VAR __table = SUMMARIZE(TimeTransactions;[Maand];"__value"; [GuideLine])
Return
IF(HASONEVALUE(TimeTransactions[Project]); [GuideLine];SUMX(__table; [__value]))

Debe resumir por lo que está resumiendo en la visualización de la tabla (se parece a "Maand"). El valor (__value) debe ser la medida que desea agregar correctamente en la línea total.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Mastering Power BI 2nd Edition

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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

Top Solution Authors