stuck combining multiple INDEX match formulas

Little_Ghost

New Member
Joined
Dec 13, 2010
Messages
48
Hi everyone,

I've been fumbling around with multiple INDEX MATCH formula's for a couple of days now, but I seem to be unable to figure out how to combine them.
What I need them to do is check if column A = Yes and Column B = No and if those conditions are true look up the correpsonding value in column C and return that. Then do it again for the next row, and again, and again....
It should only return values when the conditions are met. The values inbetween should be skipped.
They need to be returned in a ROW.
I tried to make it a little cleared in thes google spreadsheet:
https://docs.google.com/spreadsheets/d/1kL6hic3zLQCB0pPdQ6MocVWds8UG6RHn0KWvxbPQsxA/edit?usp=sharing

There are already 2 formula's on the sheet (3 if you count the duplicate where I included a little "error" handling) so you can get a better idea of where I am at (at least with the thought proccess).

I hope someone here can help me out :S
 

steve the fish

Well-known Member
Joined
Oct 20, 2009
Messages
7,793
Office Version
365
Platform
Windows
Try this array formula:

=INDEX($C$4:$C$16,SMALL(IF($A$4:$A$16="yes",IF($B$4:$B$16="no",ROW($C$4:$C$16)-ROW($A$3))),COLUMNS($A$1:A1)))
 

Little_Ghost

New Member
Joined
Dec 13, 2010
Messages
48
Steve! That was amazing; both in time between Q and A and in the fact that it works!!!
Not sure about pro's and con's of array formula's but I guess I'll jus stick to this one for now and try to convert it to a non aray based formula whenever I have the time.
Time to look into the workings of the formula so I understand the internals :)

***EDIT***
Aaaai! found the first problem:
The result has to be displayed in merged cells (6 columns). Array formulas don't like that :S
 
Last edited:

Little_Ghost

New Member
Joined
Dec 13, 2010
Messages
48
***EDIT***
Aaaai! found the first problem:
The result has to be displayed in merged cells (6 columns). Array formulas don't like that :S
If you unmerge the cells, type/paste the formula, ctrl+shift+enter, you vna merge the cells again and the formula is accepted but it then counts 2 columns which means it skips one entry when it finds 2 entries underneath eachother that it should display...
 

Little_Ghost

New Member
Joined
Dec 13, 2010
Messages
48
If you unmerge the cells, type/paste the formula, ctrl+shift+enter, you vna merge the cells again and the formula is accepted but it then counts 2 columns which means it skips one entry when it finds 2 entries underneath eachother that it should display...
got the above problem solved by replacing COLUMNS($A$1:A1) with COUNTA($E$5:E5,1)
 

Forum statistics

Threads
1,082,316
Messages
5,364,494
Members
400,802
Latest member
RichBRich

Some videos you may like

This Week's Hot Topics

  • populate from drop list with multiple tables
    Hi All, i have a drop list that displays data, what i want is when i select one of those from the list to populate text from different tables on...
  • Find list of words from sheet2 in sheet1 before a comma and extract text vba
    Hi Friends, Trying to find the solution on my task. But did not find suitable one to the need. Here is my query and sample file with details...
  • Dynamic Formula entry - VBA code sought
    Hello, really hope one of you experts can help with this - i've spent hours on this and getting no-where. .I have a set of data (more rows than...
  • Listbox Header
    Have a named range called "AccidentsHeader" Within my code I have: [CODE]Private Sub CommandButton1_Click() ListBox1.RowSource =...
  • Complex Heat Map using conditional formatting
    Good day excel world. I have a concern. Below link have a list of countries that carries each country unique data. [URL...
  • Conditional formatting
    Hi good morning, hope you can help me please, I have cells P4:P54 and if this cell is equal to 1 then i want row O to say "Fully Utilised" and to...
Top