Forum Discussion
Index help looking for next value (to left) of empty cell
I think that as a first step you need is simply to use your INDEX formula to select the record that matches the model. More specifically, you need to return that part of the table that forms the Amp-hours lookup.
= INDEX( Battery[[Ah at C/8]:[Ah at C/100]],
MATCH(Model, Battery[Common Name], 0 ), 0 )
I use a defined name 'Ah' to represent that array (add new name 'Ah' and paste the formula into the 'Refers to' box). Then, because it is just about impossible to look up the requested C/Rate in text Table headers, I would form a separate range or array 'C\Rate' (it looks odd but '\' is a legit character in a name) that contains {8,10,12,20,24,48,100}. To make LOOKUP ignore C/Rates for which you haven't got data I generated an intentional error. The array
= C\Rate / ISNUMBER(Ah)
contains values where results are available or #DIV/0! otherwise. The returned Ah is then given by
= LOOKUP( Requested, C\Rate / ISNUMBER(Ah), Ah )
Good luck!