The MATCH function may return an unexpected value in Excel (827317)



The information in this article applies to:

  • Microsoft Office Excel 2003
  • Microsoft Excel 2002
  • Microsoft Excel 2000
  • Microsoft Excel 97 for Windows

SYMPTOMS

When you use the MATCH function to find the position of a value in an array in a Microsoft Excel worksheet, an unexpected value may be returned.

CAUSE

This behavior may occur when the optional match_type option is omitted. In this scenario, the default match_type option value of 1 is assumed and the MATCH function will return the largest value that is less than or equal to the lookup_value that you specify. If the MATCH function does not find a match, the function will return the #NA error value.

MORE INFORMATION

The MATCH function returns the relative position of an item in an array that matches a specified value in a specified order.

The syntax of the MATCH function is:

MATCH(lookup_value,lookup_array,match_type)


Modification Type:MajorLast Reviewed:10/11/2006
Keywords:kbprb KB827317 kbAudEndUser