+ Reply to Thread
Results 1 to 11 of 11

Using nested Vlookups or Index/match?

  1. #1
    Registered User
    Join Date
    02-15-2021
    Location
    USA
    MS-Off Ver
    2019
    Posts
    8

    Using nested Vlookups or Index/match?

    I am trying to use the data from sheet 1 to populate the cells in the sheet 2. The data I need to match is the first column of sheet 1 and the first column of sheet 2, and I also need row 1 of sheet 2 to match column 2 of sheet 1. I need this data to output column 3 of sheet 1 in cell C13 of sheet 2. I have tried nesting Vlookups, or using Index/match but have not been able to accomplish this yet. What is the best way to do this? The data in sheet 1 can be rearranged if needed.
    Attached Files Attached Files
    Last edited by bakera8; 02-15-2021 at 05:28 PM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2405 (Windows 11 23H2 64-bit)
    Posts
    81,372

    Re: Using nested Vlookups or Index/match?

    Welcome to the forum.

    There are instructions at the top of the page explaining how to attach your sample workbook.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,842

    Re: Using nested Vlookups or Index/match?

    Try this in Cell B2 and copy down and across:

    =IFERROR(INDEX(Sheet1!$C$2:$C$88,MATCH(Sheet2!$A2&Sheet2!B$1,Sheet1!$A$2:$A$88&Sheet1!$B$2:$B$88,0)),"")

  4. #4
    Registered User
    Join Date
    02-15-2021
    Location
    USA
    MS-Off Ver
    2019
    Posts
    8

    Re: Using nested Vlookups or Index/match?

    Isn't this formula is combining the two numbers from A2 and B1 into one number rather than separately searching for them? When I ran the calculation error box that is what it showed it was doing

  5. #5
    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,127

    Re: Using nested Vlookups or Index/match?

    The biggest problem you have is that the column and row headers in sheet 2 are stored as TEXT, whereas in sheet 1 they are numbers.

    Look for the little green triangles in the corner of the cells. That's alerting you to a problem. Select the first one in column A (and then repeat in row 1) Drag across. Click on the icon with the black exclamation mark inside the yellow diamond inside the white square and select convert to number. Then....

    this formula works:

    =IFERROR(INDEX(Sheet1!$C$2:$C$88,MATCH(1,INDEX((Sheet1!$A$2:$A$88=$A2)*(Sheet1!$B$2:$B$88=B$1),0),0)),"")
    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

  6. #6
    Registered User
    Join Date
    02-15-2021
    Location
    USA
    MS-Off Ver
    2019
    Posts
    8

    Re: Using nested Vlookups or Index/match?

    Thanks Glenn, I always forget about the formatting.. That formula did work after I converted everything to number. I was also missing the extra index inside the match function when I tried to do it but it makes sense now

  7. #7
    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,127

    Re: Using nested Vlookups or Index/match?

    The little green triangles annoy the hell out of me... but they have their uses!!

    You're welcome.



    It would be very nice if you were to just click the Add Reputation button at the foot of any of the posts of members who helped you reach a solution.

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

  8. #8
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,842

    Re: Using nested Vlookups or Index/match?

    For the record, my formula in Post #3 above gives the exact same results... :-)

  9. #9
    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,127

    Re: Using nested Vlookups or Index/match?

    It does, if you convert the text to numbers AND if you enter it as an array formula. Hence, it didn't work. it's amazing how quickly you forget about array formulae when you shift to O365...

  10. #10
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,842

    Re: Using nested Vlookups or Index/match?

    it's amazing how quickly you forget about array formulae when you shift to O365
    Aint that the truth :-)

  11. #11
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2405 (Windows 11 23H2 64-bit)
    Posts
    81,372

    Re: Using nested Vlookups or Index/match?

    Agreed!!!

+ 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] Nested Index/Match/Match problems
    By V1T in forum Excel Formulas & Functions
    Replies: 15
    Last Post: 04-12-2019, 12:57 PM
  2. Equivalent Index/Match formula to replace these vlookups
    By barman in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 11-11-2018, 06:04 PM
  3. Index match and vlookups
    By mp3909 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-23-2017, 04:10 PM
  4. Index MATCH MATCH where I need 2 vlookups and 1 hlookup.
    By zhblack in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 06-02-2016, 03:30 PM
  5. [SOLVED] Vlookup with MATCH? Better than nested Vlookups?
    By trillium in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 12-29-2015, 06:00 PM
  6. Multiple Vlookups and index, match formula
    By alex_a in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-14-2015, 09:46 PM
  7. Nested Match(index()) vs. Match() array formula.
    By GeneralDisarray in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-14-2011, 07:57 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