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.
Buenos dias a todos.
Puede ser algo facil pero en este momento me encuentro aprendiendo acerca de Power BI, no se si me podrian ayudar con la siguiente pregunta, tengo los datos de los colores que se generaban mes a mes del 2021 y 2022, tengo que mostrar en una tabla como la siguiente imagen en la cual yo pueda comparar si el color es el mismo en los dos años o son diferentes.
Se que puedo traer los datos del año anterior con la función DATEADD, pero solo logro que funcione para datos numericos por la función CALCULATE.
No se si me podrian hacer el favor de indicarme como realizarlo.
Muchas gracias por su tiempo. Cordial saludo
Solved! Go to Solution.
@Anonymous , Using a date table and time intelligence
YTD = CALCULATE(Max(Table[Status]),DATESYTD('Date'[Date],"12/31"))
Last YTD = CALCULATE(Max(Table[Status]),DATESYTD(dateadd('Date'[Date],-1,Year),"12/31"))
Year behind = CALCULATE(Max(Table[Status]),dateadd('Date'[Date],-1,Year))
Year behind = CALCULATE(Max(Table[Status]),SAMEPERIODLASTYEAR('Date'[Date]))
refer if needed
Time Intelligence, DATESMTD, DATESQTD, DATESYTD, Week On Week, Week Till Date, Custom Period on Period,
Custom Period till date: https://youtu.be/aU2aKbnHuWs&t=145s
Power BI — Year on Year with or Without Time Intelligence
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
https://www.youtube.com/watch?v=km41KfM_0uA
Hi @Anonymous ,
According to your description, I made a sample and here is my solution.
Sample data:
Create a calculated column to compare two columns.
Column =
IF (
SUMX ( 'Table', SEARCH ( 'Table'[2021], 'Table'[2022], 1, 0 ) ) > 0,
"Yes",
"No"
)
Final output:
I attach my sample below for your reference.
Best Regards,
Community Support Team _ xiaosun
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous , Using a date table and time intelligence
YTD = CALCULATE(Max(Table[Status]),DATESYTD('Date'[Date],"12/31"))
Last YTD = CALCULATE(Max(Table[Status]),DATESYTD(dateadd('Date'[Date],-1,Year),"12/31"))
Year behind = CALCULATE(Max(Table[Status]),dateadd('Date'[Date],-1,Year))
Year behind = CALCULATE(Max(Table[Status]),SAMEPERIODLASTYEAR('Date'[Date]))
refer if needed
Time Intelligence, DATESMTD, DATESQTD, DATESYTD, Week On Week, Week Till Date, Custom Period on Period,
Custom Period till date: https://youtu.be/aU2aKbnHuWs&t=145s
Power BI — Year on Year with or Without Time Intelligence
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
https://www.youtube.com/watch?v=km41KfM_0uA
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 |
---|---|
47 | |
26 | |
19 | |
14 | |
10 |
User | Count |
---|---|
58 | |
50 | |
44 | |
19 | |
18 |