Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Sign up nowGet Fabric certified for FREE! Don't miss your chance! Learn more
Hi guys, not quite sure how to word this the best, but I am trying to create a measure that will allow me to display the variance for any of the accounts, over the previous year. For example what would be the variance in year 2017 for account 1, from year 2016, etc.
Here is some sample data:
| 2015 | Act 1 | $10 |
| 2015 | Act 2 | $31 |
| 2016 | Act 1 | $21 |
| 2016 | Act 2 | $21 |
| 2017 | Act 1 | $12 |
Solved! Go to Solution.
Hi @Anonymous
You can use this measure
variance =
VAR _year = MAX(SampleTable[Year])
VAR _thisYear = SUM(SampleTable[Price])
VAR _previousYear = CALCULATE(SUM(SampleTable[Price]),ALLEXCEPT(SampleTable,SampleTable[Account]),SampleTable[Year] = _year - 1)
RETURN
_thisYear - _previousYear
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
Hi @Anonymous
You can use this measure
variance =
VAR _year = MAX(SampleTable[Year])
VAR _thisYear = SUM(SampleTable[Price])
VAR _previousYear = CALCULATE(SUM(SampleTable[Price]),ALLEXCEPT(SampleTable,SampleTable[Account]),SampleTable[Year] = _year - 1)
RETURN
_thisYear - _previousYear
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 65 | |
| 65 | |
| 45 | |
| 21 | |
| 18 |
| User | Count |
|---|---|
| 115 | |
| 114 | |
| 38 | |
| 36 | |
| 26 |