gheyman
Well-known Member
- Joined
- Nov 14, 2005
- Messages
- 2,347
- Office Version
- 365
- Platform
- Windows
I have a commodity code in column A. then in Columns B through M I have inflation factors for each year starting in 2016 (B has an inflation factor of 2.177%, C 2017=3.419%, D 2018=.03360, E 2019=.02415, F 2020=.02701, G 2021=.0241,H 2022=.02860 and so on (Row 1 has the year Row two has the factor and A2 is where the commodity code is
(On my sheet I have commodity codes going down column A and the Factors going down the other columns as well)
On a separate sheet I have a field where I enter a commodity code in A1 Then A2 I Enter the starting year and A3 the End Year
What I need the formula to do is to look on sheet2 find the matching commodity code. Then depending on the start end year, I year it to figure out the total inflation
So if my start year was 2017 and my end year was 2019 Then it should use the 2018 and 2019 rates and result in 1.05856
=(1+(1*3.360))*(1+2.415)
I know you can do a Sumproduct but that means manually changing the formula because my start and end years change. I need something dynamic. for example someone could enter a start date of 2016 and end date of 2022
(On my sheet I have commodity codes going down column A and the Factors going down the other columns as well)
On a separate sheet I have a field where I enter a commodity code in A1 Then A2 I Enter the starting year and A3 the End Year
What I need the formula to do is to look on sheet2 find the matching commodity code. Then depending on the start end year, I year it to figure out the total inflation
So if my start year was 2017 and my end year was 2019 Then it should use the 2018 and 2019 rates and result in 1.05856
=(1+(1*3.360))*(1+2.415)
I know you can do a Sumproduct but that means manually changing the formula because my start and end years change. I need something dynamic. for example someone could enter a start date of 2016 and end date of 2022