vlookup query

nickharr

Active Member
Joined
Apr 8, 2008
Messages
251
Office Version
  1. 2019
Platform
  1. Windows
I am having problems with using the vlookup function in that the results I was expecting are not coming true on every occassion. If I make a very simple table in Sheet1 so that A1 has ABCD and A2 has EFGH and B1 has 10 and B2 has 20. If I then go to Sheet2 and enter in B1 =vlookup($A1,Sheet1!$A1:$B2,2) and then in A1 I enter ABCD I get the result of 10 which is correct but if I enter AXXD I am still getting 10 as a result instead of a zero or #N/A. Presumably it is not looking for an exact match but something similar - could someone give me some advice please?
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
You're right, it's not looking for an exact match..

To make it look for an exact match, try

=VLOOKUP($A1,Sheet1!$A1:$B2,2,FALSE)
 
Upvote 0
Jonmo1 - thanks for that - it now works a treat! Much appreciated.
 
Upvote 0

Forum statistics

Threads
1,224,587
Messages
6,179,740
Members
452,940
Latest member
Lawrenceiow

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top