Forum Discussion
Saes
4 years agoHelper I
Help with building a calculated table
Hello all, I'm hoping someone can help with this issue I've been struggling with. I'm trying to build a table in PowerBI desktop that shows inflation figures and then a calculated column, which shows a value based on the annual inflation figure - see table below.
I've built the first 3 columns with no problem, but struggling with the Earnings Value column.
The starting figure is £37.45 and that is fixed, but the other values from row 2 onwards have the inflation figure applied to it. I've tried several formulas, but cannot work out how to calculate the year-on-year increase to replicate the Earnings Value column.
Can anyone help?
| September Inflation Year | Inflation Figure | Financial Year Start | Earnings Value |
| 1998 | - | 01/04/1999 | £37.45 |
| 1999 | 2.09% | 01/04/2000 | £38.23 |
| 2000 | 4.30% | 01/04/2001 | £39.88 |
| 2001 | 2.20% | 01/04/2002 | £40.75 |
| 2002 | 2.20% | 01/04/2003 | £41.65 |
| 2003 | 3.30% | 01/04/2004 | £43.03 |
| 2004 | 3.60% | 01/04/2005 | £44.57 |
| 2005 | 3.20% | 01/04/2006 | £46.00 |
| 2006 | 4.10% | 01/04/2007 | £47.89 |
| 2007 | 4.40% | 01/04/2008 | £49.99 |
| 2008 | 5.50% | 01/04/2009 | £52.74 |
| 2009 | -0.90% | 01/04/2010 | £52.27 |
| 2010 | 5.10% | 01/04/2011 | £54.93 |
| 2011 | 6.10% | 01/04/2012 | £58.28 |
| 2012 | 3.10% | 01/04/2013 | £60.09 |
| 2013 | 3.70% | 01/04/2014 | £62.32 |
| 2014 | 2.20% | 01/04/2015 | £63.69 |
| 2015 | -1.00% | 01/04/2016 | £63.05 |
| 2016 | -1.00% | 01/04/2017 | £62.42 |
| 2017 | -1.00% | 01/04/2018 | £61.79 |
| 2018 | -1.00% | 01/04/2019 | £61.18 |
| 2019 | 2.70% | 01/04/2020 | £62.83 |
| 2020 | 2.50% | 01/04/2021 | £64.40 |
Saes Try this:
Column =VAR res_ = CALCULATE(((37.45*SUM(TableB[Inflation Figure])))+37.45,FILTER((TableB),TableB[September Inflation Year]<=EARLIER(TableB[September Inflation Year])))RETURN IF(TableB[September Inflation Year]=1998,37.45,res_)
8 Replies
- Tahreem24Super User
Saes For calculated column you need to replace MAX with Earlier and remove ALL.
Earning Column = CALCULATE(((SUM(TableB[Earning Value])*SUM(TableB[Inflation Figure])))+SUm(TableB[Earning Value]),FILTER((TableB),TableB[September Inflation Year]<=EARLIER(TableB[September Inflation Year])))