+ Reply to Thread
Results 1 to 13 of 13

Vlookup returns results in some cells others shows N/A

  1. #1
    Registered User
    Join Date
    09-11-2017
    Location
    Slovakia
    MS-Off Ver
    MS Office 2013
    Posts
    6

    Vlookup returns results in some cells others shows N/A

    Hello Everyone,

    Hope you guys can help me...
    I have a simple V_lookup where I try to lookup numbers. For some cells Vlookup works ok, but few cells give N/A result, even though the data are the same . I checked the formatting, I checked if the cell values are the same (excel shows as True).
    Attached is the example I've been struggling to solve. Yellow highlighted are cells I would expect excel returns a value, but it doesnt.
    Any help is very much appreciated as I've been using this daily.

    Thanks Folks!
    Attached Files Attached Files

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,053

    Re: Vlookup returns results in some cells others shows N/A

    Welcome to the wacky world of Excel....

    An array formula:
    =VLOOKUP(TRUNC(E1,2),TRUNC($A$1:$B$70,2),2,FALSE)



    Array Formulae are a little different from ordinary formulae in that they MUST be confirmed in the FIRST CELL ONLY by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. After that, the array can be dragged down as normal, to cover the desired range.

    You will know the array is active when you see curly brackets { } - or "curly braces" for those of you in the USA, or "flower brackets" for those of you in India - appear around the outside of your formula. If you do not use CTRL+SHIFT+ENTER you will (almost always) get an error message or an incorrect answer. Press F2 on that cell and try again.

    Don't type the curly brackets yourself - it won't work...

    https://support.microsoft.com/en-gb/...in-a-list-in-e
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  3. #3
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Vlookup returns results in some cells others shows N/A

    It's our old friend the floating point arithmetical precision problem - see here ... and other places

    One way without creating a helper column would be an array formula e.g. E27 - entered with Ctrl Shift Enter
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    and custom formatted as 0000000000

    Otherwise with a helper column which contains =ROUND(A1,2) and use the helper column in your lookup.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  4. #4
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,466

    Re: Vlookup returns results in some cells others shows N/A

    Normally try to Copy a blank cell then copy to column A by paste special/ Add

    In this case it does not work but I dont know why.

    Try a helper column G, in G1:
    =TEXT(A1,"00.00")+0
    Copy down

    Copy G column pate special/value back to column A
    Quang PT

  5. #5
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: Vlookup returns results in some cells others shows N/A

    Try this
    Select A1:A69
    select DATA tab
    Text To columns --> Next -->Next--> Finish
    Now VLOOKUP Works ok.
    Pl note
    Array formula should be confirmed with Ctrl+Shift+Enter keys together.
    If answere is satisfactory press * to add reputation.

  6. #6
    Valued Forum Contributor
    Join Date
    05-11-2013
    Location
    Wales
    MS-Off Ver
    Excel 2010
    Posts
    586

    Re: Vlookup returns results in some cells others shows N/A

    Hi Martin,

    Welcome to Excel Forum.

    I re-entered the values in E27 and E30 and the problem went away ???

    Regards

    peterrc

  7. #7
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Vlookup returns results in some cells others shows N/A

    How do the values get into column A ?
    Are they the result of a formula that you have done copy / paste special on ?

  8. #8
    Registered User
    Join Date
    09-11-2017
    Location
    Slovakia
    MS-Off Ver
    MS Office 2013
    Posts
    6

    Re: Vlookup returns results in some cells others shows N/A

    Thank you, Glenn, this works. Actually it solves another issue I had with importing excel file for the MS word mail merge.
    One question though, how did you manage to show excel full string in E27 and A48? Just of of curiosity.
    Thanks
    Martin

  9. #9
    Registered User
    Join Date
    09-11-2017
    Location
    Slovakia
    MS-Off Ver
    MS Office 2013
    Posts
    6

    Re: Vlookup returns results in some cells others shows N/A

    Thank you, Richard. This helps.

  10. #10
    Registered User
    Join Date
    09-11-2017
    Location
    Slovakia
    MS-Off Ver
    MS Office 2013
    Posts
    6

    Re: Vlookup returns results in some cells others shows N/A

    Hi Quang, I tried copy paste special, it didnt work, that's why I opend this thread. Anyway thanks for the second hint.

  11. #11
    Registered User
    Join Date
    09-11-2017
    Location
    Slovakia
    MS-Off Ver
    MS Office 2013
    Posts
    6

    Re: Vlookup returns results in some cells others shows N/A

    Good and quick solution, thanks.

  12. #12
    Registered User
    Join Date
    09-11-2017
    Location
    Slovakia
    MS-Off Ver
    MS Office 2013
    Posts
    6

    Re: Vlookup returns results in some cells others shows N/A

    Hi Jonmo1, it's a result of the formula =A1*-1, so I got a negative number for v_lookup and then simple copy paste values.

  13. #13
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,053

    Re: Vlookup returns results in some cells others shows N/A

    Hi. I just manually increased the number of decimals.... I forgot to restore them before posting!!

    Anyhow, glad you got sorted,

    You're welcome.



    If that takes care of your original question, please select "Thread Tools" from the menu link above and mark this thread as SOLVED.

    It'd also be appreciated if you were to click the Add Reputation button at the foot of any of the posts of all members who helped you reach a solution.

+ 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 returns results to left of primary key
    By bryanhope in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 08-09-2017, 05:50 PM
  2. Replies: 1
    Last Post: 04-26-2017, 09:08 AM
  3. Cell Value Shows Time But Value returns as Decimal
    By realniceguy5000 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-14-2011, 09:15 AM
  4. Replies: 4
    Last Post: 08-25-2010, 02:43 PM
  5. VLOOKUP inconsistently returns formula calculated cells.
    By tonyd1 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 11-07-2009, 03:55 AM
  6. Formula BOx shows Results but Cell Does not
    By Dcdrj2 in forum Excel General
    Replies: 4
    Last Post: 03-23-2007, 07:20 PM
  7. Replies: 1
    Last Post: 03-09-2006, 04:00 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