+ Reply to Thread
Results 1 to 5 of 5

VLOOKUP with merged cells as the lookup_value

  1. #1
    Registered User
    Join Date
    12-13-2019
    Location
    Chattanooga, Tennessee
    MS-Off Ver
    2013
    Posts
    2

    VLOOKUP with merged cells as the lookup_value

    I am trying to use the value in column D (merged cell) and pull all values from Column J (non merged cells) into another sheet within the spreadsheet. I have tried using the vlookup formula but I only get the first associated value from column J instead of all of them (there can be anywhere from 1 -8 values in column J). I do not know how to get this data transferred over correctly.
    Attached Images Attached Images
    Attached Files Attached Files
    Last edited by sarahgreff; 12-13-2019 at 03:16 PM.

  2. #2
    Forum Expert PaulM100's Avatar
    Join Date
    10-09-2017
    Location
    UK
    MS-Off Ver
    Office 365
    Posts
    2,108

    Re: VLOOKUP with merged cells as the lookup_value

    Don't use merged cells, try this instead https://www.businessmanagementdaily....nter-in-excel/
    Click the * to say thanks.

  3. #3
    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
    43,984

    Re: VLOOKUP with merged cells as the lookup_value

    Merged cells - the work of Satan!! You should NEVER use them.

    A picture is worth 1000 words, a sample sheet is worth 1000 pictures!!

    You have attached a non-editable picture of an Excel sheet. That's not very easy to work with. Also... I'm lazy. I have to re-type your information before I can begin to address your problem. That puts me off completely.

    So.... Do yourself a favour and please attach a SMALL sample Excel workbook (10-20 rows of data is usually enough). However, please give us an indication of the approximate number of rows of data you want the solution to work with (100, 1000, 100,000 or whatever).

    Unfortunately the attachment icon doesn't work at the moment. So,... instead click on Go Advanced (below the Edit Window) while composing your reply, then scroll down to and click on Manage Attachments and the Upload window will open. Click on Browse and navigate to (and double-click) the file icon that you want to attach, then click on Upload and then on Close this Window to return to the Edit window. When you have finished composing your post, click on Submit Post.

    Make sure confidential information is removed first!!!!
    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

  4. #4
    Registered User
    Join Date
    12-13-2019
    Location
    Chattanooga, Tennessee
    MS-Off Ver
    2013
    Posts
    2

    Re: VLOOKUP with merged cells as the lookup_value

    Glenn,
    I attached a spreadsheet of a sample of data. Basically when the SKU in column D of the sales sheet, I want it to pull the all
    EP product ID's from the EP Bundle list sheet from the same SKU that is associated in D of that same page. The original file for
    the EP Bundle List is 8,000 lines long and has the SKU in column D listed several times but the results in column J are the same
    for each time it is listed. The sample of data on the Sales sheet is just a few items that we sold in one month. I need to do
    this for an entire year. But If I can get the right formula then it should be no problem. I just don't know what that is yet.
    Attached Files Attached Files
    Last edited by sarahgreff; 12-13-2019 at 03:59 PM.

  5. #5
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,532

    Re: VLOOKUP with merged cells as the lookup_value

    There are probably more complicated formulas that will do what you want however I suggest the use of two helper columns which may be moved and/or hidden for aesthetic purposes.
    One helper column is in column K of the EP Bundle list sheet and is populated using: =IF(ISTEXT(D2),D2,K1)
    The other helper column is in column F of the Sales sheet and is populated using: =IF(ISTEXT(D2),D2,F1)
    Column E on the Sales sheet is populated using: =INDEX('EP Bundle List'!J$2:J$19,AGGREGATE(15,6,(ROW(J$2:J$19)-ROW(J$1))/('EP Bundle List'!$K$2:$K$19=F2),COUNTIFS(F$2:F2,F2)))
    Note that since you said the SKU's are listed several times, I suggest that you use a pivot table as modeled on the PT sheet.
    Let us know if you have any questions.
    Attached Files Attached Files
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

+ 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. Vlookup with merged cells
    By saligatvis in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 05-06-2019, 11:48 PM
  2. How to use Vlookup with merged cells
    By Fannyp in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-16-2018, 03:36 AM
  3. Vlookup formula can't detect value in indicated cells for lookup_value
    By lianweiling in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 02-05-2018, 02:28 AM
  4. Using multiple cells in VLOOKUP function for lookup_value - possible?
    By Vitalite in forum Excel Formulas & Functions
    Replies: 16
    Last Post: 08-05-2017, 10:42 AM
  5. Vlookup and merged cells
    By hkaric in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 05-08-2017, 10:42 AM
  6. Vlookup with merged cells
    By looeej in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-20-2016, 12:24 AM
  7. VLOOKUP across merged cells
    By WAR in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-28-2005, 02:05 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