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.
¡Hola a todos!
Tengo la siguiente tabla:
Mes | Id | Peso |
Enero | 1 | 10 |
Enero | 2 | 15 |
Enero | 3 | 20 |
Febrero | 4 | 15 |
Febrero | 5 | 20 |
Febrero | 6 | 25 |
Marzo | 7 | 20 |
Marzo | 8 | 25 |
Marzo | 9 | 30 |
Total | 180 |
Necesito crear una medida para obtener el PESO TOTAL y todavía obtiene el resultado correcto, incluso filtro la tabla.
Para el ejemplo, si filtro por mes - Enero e ID 1 y 2, quiero una medida que pueda obtener la suma total.
Algo como esto (columna TOTAL WEIGHT es el resultado esperado que necesito):
Mes | Id | Peso | PESO TOTAL |
Enero | 1 | 10 | 25 |
Enero | 2 | 15 | 25 |
Total | 25 | 25 |
He probado las medidas siguientes:
Solved! Go to Solution.
Para el peso
CALCULATE(Peso)
para sub total
CALCULATE(Weight, ALLselected(Table))
CALCULATE(Weight, allexpect(Table,Table[Month]))
Además, ¿cómo se puede utilizar removefilters
https://www.linkedin.com/pulse/five-recent-power-bi-functions-you-should-use-more-often-amit-chandak
Hola @henriquemalone ,
Puede crear una medida como DAX a continuación.
TOTAL WEIGHT = CALCULATE(SUM(Table1[Weight]),ALLSELECTED(Table1))
Percent = DIVIDE(SUM(Table1[Weight]), CALCULATE(SUM(Table1[Weight]) , ALLSELECTED(Table1)))
or use the measure:
Percent = DIVIDE(SUM(Table1[Weight]), [TOTAL WEIGHT])
Saludos
Amy
Equipo de apoyo a la comunidad _ Amy
Si este post ayuda,entonces considere Aceptarlo como la solución para ayudar a los otros miembros a encontrarlo más rápidamente.
Para el peso
CALCULATE(Peso)
para sub total
CALCULATE(Weight, ALLselected(Table))
CALCULATE(Weight, allexpect(Table,Table[Month]))
Además, ¿cómo se puede utilizar removefilters
https://www.linkedin.com/pulse/five-recent-power-bi-functions-you-should-use-more-often-amit-chandak
@henriquemalone añadir una medida como esta
Total Weight = CALCULATE ( SUM ( Table[Weight] ), ALL ( Table ) )
Me gustaría❤ elogiossi mi solución ayudara.👉Si puedes pasar tiempo publicando la pregunta, también puedes hacer esfuerzos para dar a Kudos quien haya ayudado a resolver tu problema. ¡Es una muestra de agradecimiento!
⚡Visítenos enhttps://perytus.com, su ventanilla única para proyectos/formación/consulta relacionados con Power BI.⚡
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.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.