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.
Estoy tratando de crear un gráfico de barras para que cada venta total mensual de ventas amonut compare el promedio del mes actual y el mismo mes del año pasado. Cualquier ayuda es apreciada!
Ventas | Fecha | Cantidad |
A | 1-1-2020 | 100 |
B | 1-2-2020 | 50 |
C | 1-2-2020 | 150 |
D | 1-3-2019 | 50 |
E | 1-2-2019 | 80 |
F | 1-1-2019 | 50 |
@Daming-Song , puede usar la inteligencia de tiempo y el calendario de fechas
MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD('Date'[Date]))
last MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD(dateadd('Date'[Date],-1,MONTH)))
last month Sales = CALCULATE(SUM(Sales[Sales Amount]),previousmonth('Date'[Date]))
last MTD (complete) Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD(ENDOFMONTH(dateadd('Date'[Date],-1,MONTH))))
last year MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD(dateadd('Date'[Date],-12,MONTH)))
last year MTD (complete) Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD(ENDOFMONTH(dateadd('Date'[Date],-12,MONTH))))
Month behind Sales = CALCULATE(SUM(Sales[Sales Amount]),dateadd('Date'[Date],-1,Month))
Year behind Sales = CALCULATE(SUM(Sales[Sales Amount]),dateadd('Date'[Date],-1,Year))
previous month value = CALCULATE(sum('table'[total hours value]),previousmonth('Date'[Date]))
Last year same month value = CALCULATE(sum('table'[total hours value]),previousmonth(dateadd('Date'[Date],-12,MONTH)))
Power BI — YTD
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
Para obtener lo mejor de la función de inteligencia del tiempo. Asegúrese de que tiene un calendario de fechas y que se ha marcado como la fecha en la vista de modelo. Además, únase a ella con la columna de fecha de su/s hecho/s. Consulte:
https://radacad.com/creating-calendar-table-in-power-bi-using-dax-functions
https://www.archerpoint.com/blog/Posts/creating-date-table-power-bi
https://www.sqlbi.com/articles/creating-a-simple-date-table-in-dax/
Vea si mi seminario web sobre Time Intelligence puede ayudar: https://community.powerbi.com/t5/Webinars-and-Video-Gallery/PowerBI-Time-Intelligence-Calendar-WTD-Y...
Apreciamos tus Felicitaciones.
@Daming-Song Como práctica recomendada, agregue la dimensión de fecha en el modelo y utilelo para los cálculos de inteligencia de tiempo y tiempo. Una vez agregada la dimensión de fecha, márquela como una tabla de fechas en las herramientas de tabla.
https://perytus.com/2020/05/22/create-a-basic-date-table-in-your-data-model-for-time-intelligence-ca...
Una vez que tenga una dimensión de fecha, cree una medida para el promedio y utilice la función SAMEPERIODLASTYEAR para obtener el promedio del año anterior, y estará listo. La clave es agregar dimensión de fecha en el modelo.
Me gustaría ❤ elogios si 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 en https://perytus.com, su ventanilla única para proyectos/formación/consulta relacionadas 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.
¡Gracias por tu ayuda! Tengo la medida para el promedio del mes actual y el mismo mes del año pasado. En mi gráfico de barras, puse las ventas como el Eje, el total de venta mensual de la venta y el promedio del mes actual y el mismo mes del año pasado como el valor. El gráfico de barras solo muestra el total mensual de la venta y el promedio del mes actual, el mismo mes que el promedio del año pasado no aparece. ¿Alguna solución para esto?
Hola
Comparte el enlace desde donde puedo descargar tu archivo PBI y mostrar el resultado esperado.
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.
User | Count |
---|---|
2 | |
1 | |
1 | |
1 | |
1 |
User | Count |
---|---|
2 | |
2 | |
2 | |
2 | |
1 |