+ Reply to Thread
Results 1 to 9 of 9

VLookup Fail

  1. #1
    Forum Contributor
    Join Date
    09-21-2014
    Location
    USA
    MS-Off Ver
    2010
    Posts
    449

    VLookup Fail

    Why am I having this issue doing vLookups??

    In Sheet1 column B, I am trying to return the values on Sheet2 Column B. This is a small example of a larger issue I am having on my spreadsheet.

    See Attached Book21.xlsx

  2. #2
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,501

    Re: VLookup Fail

    the data you posted in your sheet in sheet1 doesn't appear to exist in sheet2, that would be one reason you don't get any back.
    Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
    Sam Capricci

  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,791

    Re: VLookup Fail

    None of the values in Sheet1 match exactly with those in Sheet2, so you are getting #N/A errors. Also, some of the values in column A of Sheet1 are numbers and others are text values that look like numbers, whereas in Sheet2 they are only numbers. (Also, your Calculation Mode is set to Manual).

    If you change your formula in B2 of Sheet1 to this:

    =VLOOKUP(A2*1,Sheet2!A:B,2)

    then you will get the final number in Sheet2, as all your lookup values are larger.

    Hope this helps.

    Pete

  4. #4
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: VLookup Fail

    Two more reasons other than what Sambo has mentioned.
    1) Numbers in col. A on Sheet1 are formatted as text.
    2) Calculation Option is set to Manual. Set it to Automatic. Formulas Tab --> Calculation Options --> Automatic

    You may use this formula rather to get rid of formatting issue.

    In B2
    Please Login or Register  to view this content.
    and copy down.
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  5. #5
    Forum Contributor
    Join Date
    09-21-2014
    Location
    USA
    MS-Off Ver
    2010
    Posts
    449

    Re: VLookup Fail

    Is it possible for me to just change the format on both sheets when this happens? Example, Select the entire column, right click, Format cells, and select "General"?

  6. #6
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,501

    Re: VLookup Fail

    it is difficult to diagnose the reason you are getting "#N/A" in your sheet1 because the sample you posted, the values in sheet1 weren't in sheet2 as I noted.
    Any other reasons - we can't tell. If you have some hidden spaces in one and not in the other that wouldn't be apparent unless the values in sheet1 existed also in sheet2, then we'd have something to look for. Formatting them the same is usually a good idea though.

  7. #7
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,791

    Re: VLookup Fail

    The *1 in the formula that I gave you (and sktneer as well) will take care of it, as long as you have only numbers in column A of Sheet2.

    Hope this helps.

    Pete

  8. #8
    Forum Contributor
    Join Date
    09-21-2014
    Location
    USA
    MS-Off Ver
    2010
    Posts
    449

    Re: VLookup Fail

    Quote Originally Posted by Pete_UK View Post
    The *1 in the formula that I gave you (and sktneer as well) will take care of it, as long as you have only numbers in column A of Sheet2.

    Hope this helps.

    Pete
    Thanks Pete!

  9. #9
    Forum Contributor
    Join Date
    09-21-2014
    Location
    USA
    MS-Off Ver
    2010
    Posts
    449

    Re: VLookup Fail

    Had to come back to this today! Realize I didn't marked he thread as solved. Thanks all

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How to make a cell display "FAIL" when range of cells is FAIL
    By crazychile in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 07-18-2017, 04:13 PM
  2. Application Fail
    By jeff_kaufman in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 11-17-2013, 07:11 PM
  3. [SOLVED] Need a formula for pass/fail based on no. of Y answers but automatically fail if 3a is N
    By Researcher1111 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 09-15-2013, 10:20 PM
  4. [SOLVED] Vlookup begins to fail after so many cells
    By calee1983 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-25-2013, 01:33 PM
  5. [SOLVED] why does this fail?
    By Gixxer_J_97 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-18-2005, 08:06 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1