Lookup and Reference - MATCH Function

The MATCH Function searches for a specified item in a range of cells, and then returns the relative position of that item in the range.
Use MATCH instead of one of the LOOKUP Functions when you need the position of an item in a range instead of the item itself. E.g. you can use the MATCH Function to provide a value for the row_num argument of the INDEX Function.
MATCH (lookup_value, lookup_array, [match_type])

The value that you want to match in lookup_array. E.g. when you look up someone's number in a telephone book, you are using the person's name as the lookup value, but the telephone number is the value you want.
The lookup_value argument can be a value (number, text, or logical value) or a cell reference to a number, text, or logical value.
The range of cells being searched.
The number -1, 0, or 1.
The match_type argument specifies how Excel matches lookup_value with values in lookup_array.
The default value for this argument is 1.
See below to know how the function finds values based on the match_type argument.
MATCH finds the largest value that is less than or equal to lookup_value.
The values in the lookup_array argument must be placed in ascending order, for example: ...-2, -1, 0, 1, 2... A-Z, FALSE, TRUE.
MATCH finds the first value that is exactly equal to lookup_value.
The values in the lookup_array argument can be in any order.
MATCH finds the smallest value that is greater than or equal to lookup_value.
The values in the lookup_array argument must be placed in descending order, for example: TRUE, FALSE, Z-A ...2, 1, 0, -1, -2..., and so on.
MATCH returns the position of the matched value within lookup_array, not the value itself. E.g. MATCH ("b",{"a","b","c"},0) returns 2, which is the relative position of "b" within the array {"a","b","c"}
MATCH returns the position of the matched value within lookup_array, not the value itself. E.g. MATCH ("b",{"a","b","c"},0) returns 2, which is the relative position of "b" within the array {"a","b","c"}
MATCH does not distinguish between uppercase and lowercase letters when matching text values.
MATCH does not distinguish between uppercase and lowercase letters when matching text values.
If MATCH is unsuccessful in finding a match, it returns the #N/A error value.
If MATCH is unsuccessful in finding a match, it returns the #N/A error value.
If match_type is 0 and lookup_value is a text string, you can use the wildcard characters - the question mark (?) and asterisk (*) - in the lookup_value argument

A question mark matches any single character
An asterisk matches any sequence of characters
If you want to find an actual question mark or asterisk, type a tilde (~) before the character


If match_type is 0 and lookup_value is a text string, you can use the wildcard characters - the question mark (?) and asterisk (*) - in the lookup_value argument
A question mark matches any single character
A question mark matches any single character
An asterisk matches any sequence of characters
An asterisk matches any sequence of characters
If you want to find an actual question mark or asterisk, type a tilde (~) before the character
If you want to find an actual question mark or asterisk, type a tilde (~) before the character
If the lookup_array not being ordered correctly, Match Function returns the wrong result
If the lookup_array not being ordered correctly, Match Function returns the wrong result
Match Function returns a #N/A error value when the Function fails to find a match for the lookup_value. This can happen

If match_type = 0 and an exact match for the lookup_value is not found within the lookup_array
If match_type = 1 or is omitted and the first value in the lookup_array is larger than the if match_type = 1 lookup_value (i.e., the array is in ascending order and there is no closest match below or equal to the lookup_value).
If match_type = -1 and the first value in the lookup_array is smaller than the lookup_value (and therefore, if the array is in descending order, there is no closest match above or equal to the lookup_value).
If there are unseen characters in either the lookup_value or the values in the lookup_array.
If  lookup_value and the data in the lookup_array have different data types.


Match Function returns a #N/A error value when the Function fails to find a match for the lookup_value. This can happen
If match_type = 0 and an exact match for the lookup_value is not found within the lookup_array
If match_type = 0 and an exact match for the lookup_value is not found within the lookup_array
If match_type = 1 or is omitted and the first value in the lookup_array is larger than the if match_type = 1 lookup_value (i.e., the array is in ascending order and there is no closest match below or equal to the lookup_value).
If match_type = 1 or is omitted and the first value in the lookup_array is larger than the if match_type = 1 lookup_value (i.e., the array is in ascending order and there is no closest match below or equal to the lookup_value).
If match_type = -1 and the first value in the lookup_array is smaller than the lookup_value (and therefore, if the array is in descending order, there is no closest match above or equal to the lookup_value).
If match_type = -1 and the first value in the lookup_array is smaller than the lookup_value (and therefore, if the array is in descending order, there is no closest match above or equal to the lookup_value).
If there are unseen characters in either the lookup_value or the values in the lookup_array.
If there are unseen characters in either the lookup_value or the values in the lookup_array.
If  lookup_value and the data in the lookup_array have different data types.
If  lookup_value and the data in the lookup_array have different data types.
Excel 2007, Excel 2010, Excel 2013, Excel 2016

    296 Lectures 
     146 hours 

 Arun Motoori

    56 Lectures 
     5.5 hours 

 Pavan Lalwani

    120 Lectures 
     6.5 hours 

 Inf Sid

    134 Lectures 
     8.5 hours 

 Yoda Learning

    46 Lectures 
     7.5 hours 

 William Fiset

    25 Lectures 
     1.5 hours 

 Sasha Miller
 Print
 Add Notes
 Bookmark this page