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,
I am trying to find the % difference e.g. change in consumption between 2021 and 2020 then 2022 and 2021:
This is not a calculated column so can be edited in Power Query editor
Thanks!
Solved! Go to Solution.
Hi, @kadekwijaya
You can try the following methods.
Measure:
Change% =
Var _Previousyear=CALCULATE(SUM('Table'[Consumption]),FILTER(ALL('Table'),[Year]=SELECTEDVALUE('Table'[Year])-1))
Var _Currentyear=SUM('Table'[Consumption])
Return
IF(_Previousyear=BLANK(),BLANK(),DIVIDE(_Currentyear-_Previousyear,_Currentyear))
Column =
Var _Previousyear=CALCULATE(SUM('Table'[Consumption]),FILTER('Table',[Year]=EARLIER('Table'[Year])-1))
Var _Currentyear=[Consumption]
Return
IF(_Previousyear=BLANK(),BLANK(),DIVIDE(_Currentyear-_Previousyear,_Currentyear))
Is this the result you expect?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
hi @kadekwijaya
you want a solution in PQ?
With DAX, try plot a visual with Year column and a measure like:
Thanks for the suggestion!
I would ideally like a table showing the change in consumption as a % between each year?
E.g. 2020 will be blank but 2021 and 2022 will have % values?
Hi, @kadekwijaya
You can try the following methods.
Measure:
Change% =
Var _Previousyear=CALCULATE(SUM('Table'[Consumption]),FILTER(ALL('Table'),[Year]=SELECTEDVALUE('Table'[Year])-1))
Var _Currentyear=SUM('Table'[Consumption])
Return
IF(_Previousyear=BLANK(),BLANK(),DIVIDE(_Currentyear-_Previousyear,_Currentyear))
Column =
Var _Previousyear=CALCULATE(SUM('Table'[Consumption]),FILTER('Table',[Year]=EARLIER('Table'[Year])-1))
Var _Currentyear=[Consumption]
Return
IF(_Previousyear=BLANK(),BLANK(),DIVIDE(_Currentyear-_Previousyear,_Currentyear))
Is this the result you expect?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
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.