Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi there,
I was requested in a matrix to show the % variance from 2025 vs 2024 instead of the sum as a total. Is this possible? Consider that all the values in the columns are measures.
Thanks for the guidance.
Solved! Go to Solution.
@dustdaniel Well, not much information to go on so not sure how specific and accurate I can be but let's say you have a measure called "Dias", you could create the following measure and use it in your visualization instead:
Dias Total =
VAR __Dias = [Dias]
VAR __Dias2025 = CALCULATE( [Dias], 'Dates'[Year] = 2025 )
VAR __Dias2024 = CALCULATE( [Dias], 'Dates'[Year] = 2024 )
VAR __Result = IF( HASONEVALUE( 'Dates'[Year] ), __Dias, __Dias2025 - __Dias2024 )
RETURN
__Result
@dustdaniel So yes. You could add a check in your measure formulas to check if there is a single value for Year. If not, then you are in a Total row and you can determine what to do from there. For example.
@dustdaniel Well, not much information to go on so not sure how specific and accurate I can be but let's say you have a measure called "Dias", you could create the following measure and use it in your visualization instead:
Dias Total =
VAR __Dias = [Dias]
VAR __Dias2025 = CALCULATE( [Dias], 'Dates'[Year] = 2025 )
VAR __Dias2024 = CALCULATE( [Dias], 'Dates'[Year] = 2024 )
VAR __Result = IF( HASONEVALUE( 'Dates'[Year] ), __Dias, __Dias2025 - __Dias2024 )
RETURN
__Result
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 41 | |
| 37 | |
| 35 | |
| 35 | |
| 28 |
| User | Count |
|---|---|
| 134 | |
| 101 | |
| 71 | |
| 67 | |
| 65 |