Select multiple cells to perform product

Copper Contributor

Hello

 

Help!

 

Is there a formula/function that will enable me to find the product of all the values between two of the dates. for example, in the table below I may need it for from 2020 to 2022 so I'll need a formula that will give me 108.6*109.4*117.1.

 

DateValue
01/03/2022117.1
01/03/2021109.4
01/03/2020108.6
01/03/2019107
01/03/2018105
01/03/2017102.5
01/03/2016100.2
01/03/201599.7
01/03/201499.7
01/03/201398.1
01/03/201295.4

 

I effectively need something where I can tell it the two dates, and it will give me the product of all the values between those two dates. I thought it would be as easy as using the CELL function to get the cell names into the PRODUCT function but I can't seem to get that to work

 

Sorry if I'm not making this clear - any help will be greatly appreciated!

 

Thanks!

 

1 Reply
Apologies if there's a way to mark this as solved.

Formula here - =PRODUCT(IF((YEAR(A2:A12)>=2020)*(YEAR(A2:A12)<=2022),B2:B12))