+ Reply to Thread
Results 1 to 6 of 6

Need to Combine 2 Workbooks with a Common Column Header

  1. #1
    Registered User
    Join Date
    10-14-2009
    Location
    Texas
    MS-Off Ver
    Excel 2003
    Posts
    3

    Need to Combine 2 Workbooks with a Common Column Header

    I have 2 Excel workbooks that were sent to me and I need to combine them. They have a common column called "Product SKU," but each additional and different columns. How can I combine the 2 workbooks so that one master workbook shows all of the common column data for each Product Sku.

    Also, and I don't know if this matters, one of the workbooks has some additional Product Skus that aren't on the other workbook.

    Thank you for any advice.

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Need to Combine 2 Workbooks with a Common Column Header

    Post up a sample of each of the workbooks. Click on GO ADVANCED and use the paperclip icon to upload them.

    Do you want the "merge" to be in one of the two workbooks, or into a third?
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    10-14-2009
    Location
    Texas
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: Need to Combine 2 Workbooks with a Common Column Header

    Okay, I have attached samples of the two workbooks with the first 40 lines. To make things easier, we can just combine "AGN-Pricing.xls" into "AGN-Pricing-main.xls."

    Please take a look at this and let me know the proper procedure for combining these two workbooks.

    Thanks,

    Mike
    Attached Files Attached Files

  4. #4
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Need to Combine 2 Workbooks with a Common Column Header

    1) In the MAIN sheet, put the titles RETAIL/COST/QTY in C1/D1/E1

    2) In C2, enter this formula then copy it down the whole dataset and across:

    =IF(ISNUMBER(MATCH($A2,[AGN_Pricing.xls]CustPricing!$A:$A,0)), INDEX([AGN_Pricing.xls]CustPricing!B:B,MATCH($A2,[AGN_Pricing.xls]CustPricing!$A:$A,0)), "")

    Once all the values appear:
    3) Highlight the 3 new columns
    4) Ctrl-C to copy
    5) Click on Edit > Paste Special > Values

    The sheets are now merged and the formulas have been removed.

  5. #5
    Registered User
    Join Date
    10-14-2009
    Location
    Texas
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: Need to Combine 2 Workbooks with a Common Column Header

    That did the trick. Thank you very much. Do you know a place where I can view a tutorial on writing formulas like that? I always like learning these things and expanding my Excel skills.

  6. #6
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Need to Combine 2 Workbooks with a Common Column Header

    This forum is a wonderful tutorial. Pick a topic/function/problem and do a search in the database of the forum. Read through the threads where people have asked about that topic and the answers given. Analyze the answers until you understand them.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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