+ Reply to Thread
Results 1 to 4 of 4

VLookup evaluating a formula field returns N/A

  1. #1
    Registered User
    Join Date
    09-05-2019
    Location
    Mississippi, USA
    MS-Off Ver
    2016
    Posts
    2

    Exclamation VLookup evaluating a formula field returns N/A

    I have a spreadsheet that has one tab that includes 2 columns: student ID and grade. Some student IDs are prefaced with a "w" and some are not.
    The same spreadsheet has another tab with 2 columns: student ID and student name. None of the student IDs are prefaced with a "w"

    I am trying to do a vlookup on the student ID on the first tab so that the student name is returned from the 2nd tab to a field on the 1st tab.

    So that all of the student IDs are the same format, I applied this formula to remove the "w" from the student ID on the first tab: =MID(A13,2,10).

    My vlookup works great on the rows that already existed without the "w". But on the cells that have the formula above, it returns N/A. When I evaluate the formula, it seems like it is finding the right student ID (without the "w") but it still returns N/A.

    Any help would be appreciated.

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

    Re: VLookup evaluating a formula field returns N/A

    When you use MID on those IDs with a "w", the formula will return a text value that looks like a number. You can convert it to an actual number in several ways, e.g.:

    =MID(A13,2,10)+0

    =MID(A13,2,10)*1

    =--MID(A13,2,10)

    =VALUE(MID(A13,2,10))

    VLOOKUP will not match a number with a text value that looks like a number, so you have to ensure that all the lookup values have the same format type.

    Hope this helps.

    Pete

  3. #3
    Registered User
    Join Date
    09-05-2019
    Location
    Mississippi, USA
    MS-Off Ver
    2016
    Posts
    2

    Re: VLookup evaluating a formula field returns N/A

    Genius!!! That worked perfectly! Thank you!

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

    Re: VLookup evaluating a formula field returns N/A

    You're welcome - glad to help.

    If that takes care of your original question, please take a moment to select Thread Tools from the menu above and to the right of your first post in this thread, and mark the thread as SOLVED.

    Also, you might like to know that you can directly thank those who have helped you and show your appreciation of their efforts by clicking on the small "star" icon located in the lower left corner of a post that you have found to be helpful (not just in this thread - for any post that has helped you). This also adds to the reputation of the poster (the small green bars in the poster's profile).

    Pete

+ 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. [SOLVED] VLOOKUP formula does not return expected value. Suspected error in formula. Returns N/A
    By ZMAFC94 in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 07-31-2018, 04:33 AM
  2. Can I get a Result Evaluating a Row Field.
    By lectorfiel in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 04-11-2015, 11:59 PM
  3. Evaluating by vlookup and sumproduct formula
    By paradise2sr in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 07-21-2013, 08:27 AM
  4. Excel 2007 : Evaluating after a Vlookup
    By rlaubhan in forum Excel General
    Replies: 1
    Last Post: 11-11-2010, 05:25 PM
  5. VLookup Formula returns #NA
    By Coors in forum Excel General
    Replies: 1
    Last Post: 09-17-2009, 03:12 PM
  6. vlookup formula only returns ref# or n/A
    By cinco5 in forum Excel General
    Replies: 10
    Last Post: 10-22-2008, 10:35 AM
  7. @vlookup returns the formula instead of the value - why?
    By Barb in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-05-2006, 05:40 PM

Tags for this Thread

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