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!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hi all,
I'm trying to create a measure that will calculate the delta between selected planning version. My simplified datamodel is as follows:
Version | value |
Planning_1 | 10 |
Planning_2 | 20 |
Planning_3 | 25 |
Planning_4 | 8 |
Result should be usable in a matrix visual:
column1: planning version A
column2: planning version b
column 3: delta
Thanks you very much for your respons!
Regards,
Paul Theunissen
Solved! Go to Solution.
Hi @Anonymous
One idea,
create the measure
Measure =
var _count= COUNTX(ALLSELECTED('Table'[Version]),[Version])
var _max= IF(_count=2,MAXX(ALLSELECTED('Table'),'Table'[value]))
var _min= IF(_count=2,MINX(ALLSELECTED('Table'),'Table'[value]))
return
IF(HASONEVALUE('Table'[Version]),SUM('Table'[value]),_max-_min)
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous
One idea,
create the measure
Measure =
var _count= COUNTX(ALLSELECTED('Table'[Version]),[Version])
var _max= IF(_count=2,MAXX(ALLSELECTED('Table'),'Table'[value]))
var _min= IF(_count=2,MINX(ALLSELECTED('Table'),'Table'[value]))
return
IF(HASONEVALUE('Table'[Version]),SUM('Table'[value]),_max-_min)
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
Thanks! This helps a lot. One more question. Is it also possible to create a measure that calculates a difference for multiple dimension: Version, cost center and year, quarter and month?
example:
In the matrix the expected result shoud be:
when planing_1 and planning_2 are selected:
Hi:
I looked up a potential solution for you. Please check out this previous answer and I hope this helps!
Thanks for your help. Unfortunately this solution doesn't work for me... I get the message that I want to compare text with numbers
Hi Paul:
Can you give sme examples of expected results? I'm not sure what you want to compare your selected value to? Thanks..
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.