Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VLOOKUP returning wrong row

I have a fairly simple lookup table:

enter image description here

The formula I have in B6 is:

=VLOOKUP(A6,C1:D4,2)

So I would expect it to return 1, not 4?

like image 899
Bill Avatar asked Jul 17 '26 04:07

Bill


1 Answers

You are omitting the sorted flag, which then defaults to TRUE thus making it ignore the exact match.

Quoting Google Help:

It’s recommended to set is_sorted to FALSE. If set to FALSE, an exact match is returned. If there are multiple matching values, the content of the cell corresponding to the first value found is returned, and #N/A is returned if no such value is found.

Check this image out:

enter image description here

Hope that helps, cheers!

like image 107
delimiter Avatar answered Jul 18 '26 19:07

delimiter



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!