Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more.
Get startedGrow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.
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 @theunissenp
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 @theunissenp
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..
User | Count |
---|---|
53 | |
46 | |
19 | |
16 | |
13 |
User | Count |
---|---|
108 | |
56 | |
31 | |
19 | |
18 |