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!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hi there!
I am looking for some help with my dax:
I have a very simplified dataset and I want to calculate the percent difference (V2-V1)/V1 . I would like a way to calculate the percent difference based off of different reference values: AVGstatic, AVGmonthly (calculated). I would only like to have 1 column called 'Percent difference' , but I don't know how to filter the table properly.
Thank you for your help.
Corey
OUTPUT:
AVGstatic = 6
TABLE 1:
Date | Bananas Eaten | Percent difference |
1.1.2024 | 6 | 0 |
1.2.2024 | 7 | 17% |
1.3.2024 | 8 | 33% |
AVGMonthly = 10
TABLE 1:
Date | Bananas Eaten | Percent difference |
1.1.2024 | 6 | -40% |
1.2.2024 | 7 | -30% |
1.3.2024 | 8 | -20% |
Solved! Go to Solution.
Hi @Anonymous ,
You can try dax like below:
M1 =
VAR cur =
IF (
NOT ISBLANK ( SELECTEDVALUE ( slice[tag] ) ),
SELECTEDVALUE ( slice[value] ),
BLANK ()
)
RETURN
( MAX ( 'Table'[Bananas Eaten] ) - cur ) / cur
Best Regards,
Adamk Kong
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi @Anonymous ,
You can try dax like below:
M1 =
VAR cur =
IF (
NOT ISBLANK ( SELECTEDVALUE ( slice[tag] ) ),
SELECTEDVALUE ( slice[value] ),
BLANK ()
)
RETURN
( MAX ( 'Table'[Bananas Eaten] ) - cur ) / cur
Best Regards,
Adamk Kong
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
User | Count |
---|---|
15 | |
9 | |
8 | |
6 | |
5 |
User | Count |
---|---|
29 | |
18 | |
15 | |
7 | |
6 |