Multi-Criteria Lookups (INDEX-MATCH)

Multi-criteria lookups in Excel allow you to perform complex searches based on multiple conditions. This is particularly useful when you need to match data from a table based on more than one criterion.

Use INDEX and MATCH with Multiple Criteria to Perform Complex Lookups

The combination of INDEX and MATCH functions can be used to perform lookups based on multiple criteria. This method is more flexible and powerful compared to the VLOOKUP function, especially when dealing with large datasets or when the lookup value is not in the first column.

Example

Below is an example demonstrating how to use the INDEX and MATCH functions with multiple criteria.

EmployeeDepartmentSalary
AliceHR50000
BobIT60000
CharlieFinance70000
DianaIT65000
EdwardHR55000
FionaFinance72000
GeorgeIT64000
HannahHR53000
IanFinance71000
JaneIT63000

Exercise

  1. In the "Lookup Employee" (cell A15) and "Lookup Department" (cell B15) cells input the criteria for the lookup.
  2. Use the INDEX and MATCH functions to find the corresponding salary based on the entered criteria.

Solution

In the embedded sheet, the formula for finding the salary based on the lookup criteria is provided in the "Resulting Salary" column. Here is how the solution is structured:

The formula for Resulting Salary:

=INDEX(C2:C11, MATCH(1, (A2:A11=A15)*(B2:B11=B15), 0))

Explanation

  1. INDEX Function:
    • =INDEX(C2:C11, ...) specifies the range to return a value from, in this case, the Salary column (C2).
  2. MATCH Function with Multiple Criteria:
    • MATCH(1, (A2:A11=A15)*(B2:B11=B15), 0) searches for the row where both criteria are met:
      • (A2:A11=A15) checks if the Employee column matches the lookup employee in cell A15.
      • (B2:B11=B15) checks if the Department column matches the lookup department in cell B15.
      • The multiplication of these conditions creates an array of 1s and 0s, where 1 represents rows that match both criteria.
      • MATCH(1, ..., 0) finds the position of the first 1 in this array, indicating the row where both criteria are satisfied.

Using these formulas in your embedded sheet ensures that the salary is dynamically retrieved based on the specified criteria.

Please enable JavaScript in your browser to complete this form.
How would you rate this post?
Do you think adding a video explanation would be useful?
Your Excel Skill Level