+ Reply to Thread
Results 1 to 6 of 6

Lookup Returning Wrong Value

Hybrid View

  1. #1
    Registered User
    Join Date
    01-28-2018
    Location
    St. Louis, MO
    MS-Off Ver
    2010
    Posts
    10

    Lookup Returning Wrong Value

    I've attached a sample file of what I am running into issues with. I have a table of information, one column is an identifier number and the next column is the quantity associated with that identifier. The lookup is just trying to find the identifier and then return the quantity for that identify from the next column. The formula I'm using is "=IFERROR(LOOKUP(B1,Sheet1!$D$2:$E$31,Sheet1!$E$2:$E$31), "")". But it keeps either returning no number or the wrong number.

    If you open the file the lookup is on sheet 2.
    Attached Files Attached Files

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

    Re: Lookup Returning Wrong Value

    if you have a distinct set of numbers in column D (no repeats for example) then this should work for you...
    =IFERROR(INDEX(Sheet1!$E:$E,MATCH(Sheet2!B1,Sheet1!$D:$D,0)),"")

    BTW, the lookup works if the values are sorted ascending, so to return 20 you would have to sort sheet1 by column D ascending.
    Last edited by Sam Capricci; 02-15-2018 at 02:54 PM.
    Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
    Sam Capricci

  3. #3
    Forum Expert 63falcondude's Avatar
    Join Date
    08-22-2016
    Location
    USA
    MS-Off Ver
    365
    Posts
    6,266

    Re: Lookup Returning Wrong Value

    Try this in B2:

    =IFERROR(VLOOKUP(B1,Sheet1!$D:$E,2,0),"")

    Drag it through D2.

  4. #4
    Forum Expert tim201110's Avatar
    Join Date
    10-23-2011
    Location
    Russia
    MS-Off Ver
    2016, 2019
    Posts
    2,357

    Re: Lookup Returning Wrong Value


  5. #5
    Registered User
    Join Date
    01-28-2018
    Location
    St. Louis, MO
    MS-Off Ver
    2010
    Posts
    10

    Re: Lookup Returning Wrong Value

    I love this forum. Thanks everyone!

  6. #6
    Forum Expert 63falcondude's Avatar
    Join Date
    08-22-2016
    Location
    USA
    MS-Off Ver
    365
    Posts
    6,266

    Re: Lookup Returning Wrong Value

    You're welcome. Glad we could help.

+ 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. Lookup returning wrong results
    By jamesliv in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 08-05-2014, 11:13 AM
  2. IF formula returning wrong value!
    By Robotacha2010 in forum Excel General
    Replies: 4
    Last Post: 06-22-2011, 10:49 AM
  3. If Then returning wrong value
    By hawaiimovieguy in forum Excel General
    Replies: 3
    Last Post: 01-09-2007, 05:08 AM
  4. Excel 2002 Lookup formula returning wrong results?
    By Val in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 11-18-2005, 05:10 PM
  5. [SOLVED] VLOOKUP returning wrong row
    By jthomas in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 11:05 AM
  6. [SOLVED] VLOOKUP returning wrong row
    By jthomas in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 02:05 AM
  7. [SOLVED] VLOOKUP returning wrong row
    By jthomas in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-05-2005, 11:05 PM

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