Vlookup Not Working

Anonymous
2021-02-24T13:29:45+00:00

I can't get Vlookup to work between 2 workbooks using 2 simple columns. It shows 'NA' in the field where I'm feeding in this formula. This is the string I'm using:

=VLOOKUP(A2,'[Dom. Mast. Data (Dup. Rem.).xlsx]Updated Data As On 17 Mar 2020'!$A$2:$B$597,2,0)

This seems strange to see how it won't pull up the data.

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

2 answers

Sort by: Most helpful
  1. Ashish Mathur 102.4K Reputation points Volunteer Moderator
    2021-02-25T00:07:10+00:00

    Hi,

    There is no mistake in your formula. There are probably extra spaces/spelling mistakes appearing in column A of the Updated Data As On 17 Mar 2020 worksheet. Correct for those.

    Was this answer helpful?

    1 person found this answer helpful.
    0 comments No comments
  2. Rich~M 20,370 Reputation points Volunteer Moderator
    2021-02-24T17:21:53+00:00

    Hi Josy. I am an Excel user like you and will try to help.

    Though I've not seen a "0" used for the last element in the VLOOKUP, I tried it and it worked. In any event you might try to change that to "FALSE" and see if that might make a difference.

    The most likely culprit however is in the lookup data itself since you are getting NA so that it appears the formula is working. You didn't indicate what type of data you are looking up, text or numbers. If it is text the most likely problem is extra spaces, especially at the end since VLOOKUP will only find exact matches. If you are looking up a number you need to check whether both locations, your lookup value and your lookup data in the table array, are formatted the same. If one is formatted as a number and the other is not then VLOOKUP will not find a match--NA. They may look identical, but Excel will treat them differently.

    The easiest way for me to check whether both the data you looking up in A2 and the data in column A2 in the table array are both number (or both text) is to change the formatting to a different format as in Number, Currency, Date, etc. If the number changes to the new format then it is stored as number, if not it is stored as text. (Be sure to undo the change after checking it.)

    If they are different you will need to fix one of them to make them match. Just changing the formatting for the cell will not fix this. Reply with more detail if this turns out to be the problem and you need help fixing the formatting.

    Reply if you have additional questions or more information. Please mark this reply as answered it this solves your question.

    Rich~M

    Was this answer helpful?

    0 comments No comments