Donate SIGN UP

Excel VLOOKUP

Avatar Image
funkylad20 | 10:46 Thu 08th Sep 2011 | Computers
4 Answers
OK, I get Vlookup. I use it all fo the time. But this morning I am at my desk and cannot for the life of me work out why a VLOOKUP formula will not work.
I have one sheet, with lots of URN's on (i.e. 20090145). I then have another sheet with a smaller number of URN's on. Both columns where the numbers are are in column A (but different sheets).

I am asking it to look up a URN on one sheet and present the name of that URN from the first sheet. i.e. if 20090145 on sheet one is 'London', then I want it to return the text as 'London' on sheet two for that URN.

It works, BUT all of the names are incorrect! There are even some #N/A appearing.

For info, the formula I am using is (the 2 at the end is column B, the desired result):

=VLOOKUP(A3,'Sheet 1'!$A$10:$H$400,2)
Gravatar

Answers

1 to 4 of 4rss feed

Best Answer

No best answer has yet been selected by funkylad20. Once a best answer has been selected, it will be shown here.

For more on marking an answer as the "Best Answer", please visit our FAQ.
Try

=VLOOKUP(A3,Sheet 1!$A$10:$B$400,2,false)
Sounds as though the range you're searching down is in some way incorrect. Are there more than 400 rows, perhaps? Or do they start from A2 or some other field? Are you sure that some of your URN's aren't text rather than numbers, perhaps?

Do let us know how you got on.
Question Author
Chuck, that worked, so thanks. But, why? Why does it not like me using all of the data, preferring just the first two columns (admittedly the only ones I do actually need...). And why did it throw out dud responses before?
Referencing more data than you need is always likely to cause erroneous results and the false on the end specifies you need an exact match, without the false excel will return what it considers to be the closest match which is pretty close to a random result!

1 to 4 of 4rss feed

Do you know the answer?

Excel VLOOKUP

Answer Question >>