Vlookup with multiple variables

  • Thread starter Thread starter Sam
  • Start date Start date
Try this

=INDEX(A1:A10,MATCH(1,(B1:B10="value1")*(C1:C10="value2"),0))

where a1 - A10 is the value to return and the other 2 columns are the lookup
values

Mike
 
I tried the formula you suggested, but received #N/A. Is there something
wrong with my formula?

=INDEX(planning_nodes!C2:C6500,MATCH(1,(planning_nodes!A2:A6500=Editorial!A2)*(planning_nodes!G2:G6500=Editorial!D2),0))
 
Sam

Enter as an array with Ctrl+Shift+Enter and Excel will put curly brackets
around it {} and it works fine for me. You CANT type the curly brackets
yourself

Mike
 
What do the 1 and 0 do in the formula?

Mike H said:
Sam

Enter as an array with Ctrl+Shift+Enter and Excel will put curly brackets
around it {} and it works fine for me. You CANT type the curly brackets
yourself

Mike
 
Oops! My error. It works.

Thanks.

Mike H said:
Sam

Enter as an array with Ctrl+Shift+Enter and Excel will put curly brackets
around it {} and it works fine for me. You CANT type the curly brackets
yourself

Mike
 
Hi Mike. It worked, but when I went to lock in the columns to drag the
formula down, I received an error message. How do I lock the columns?

Thanks.
 
Maybe you want:

=INDEX(planning_nodes!$C$2:$C$6500,
MATCH(1,(planning_nodes!$A$2:$A$6500=Editorial!$A2)
*(planning_nodes!$G$2:$G$6500=Editorial!$D2),0))
 
Back
Top