+ Reply to Thread
Results 1 to 6 of 6

combine several rows to one if column A matches

  1. #1
    Registered User
    Join Date
    06-14-2013
    Location
    Germany
    MS-Off Ver
    Excel 2013
    Posts
    20

    combine several rows to one if column A matches

    Hello, this is probably a problem already solved somewhere but I couldnīt find it because the right keywords eluded me:

    I want to combine the strings in the column B (using ; as separator) if the identifier in column A is the same
    columnA columnB
    CE00004 IPR000911
    CE00004 IPR020783
    CE00004 IPR020784
    CE00015 IPR004365
    CE00015 IPR004523
    CE00034 IPR004911

    columnA columnB
    CE00004 IPR000911;IPR020783;IPR020784
    CE00015 IPR004365;IPR004523
    CE00034 IPR004911

    Thank you

  2. #2
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: combine several rows to one if column A matches

    Hi,

    Are you insistent on concatenating the results into a single cell or would you be satisfied with returning each match in its own column to the right?

    The latter would be relatively straightforward, though, unless you have a reasonably small upper limit on the maximum number of matches for any one identifier, the former will require either some unfeasibly long formulae or a VBA-based solution.

    Regards
    Click * below if this answer helped

    Advanced Excel Techniques: http://excelxor.com/

  3. #3
    Registered User
    Join Date
    06-14-2013
    Location
    Germany
    MS-Off Ver
    Excel 2013
    Posts
    20

    Re: combine several rows to one if column A matches

    Yes unfortunately other columns are adjacent to the column I want to combine which will be problematic if every entry gets itīs own cell.

  4. #4
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: combine several rows to one if column A matches

    Fine, then I trust someone with some VBA expertise will pick up on this thread shortly.

    Regards

  5. #5
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: combine several rows to one if column A matches

    The output is in new sheet.
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    06-14-2013
    Location
    Germany
    MS-Off Ver
    Excel 2013
    Posts
    20

    Re: combine several rows to one if column A matches

    Sorry for the late reply. The script works for me, thank you!

+ 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. Replies: 16
    Last Post: 07-02-2012, 03:46 PM
  2. Replies: 0
    Last Post: 07-06-2011, 11:31 AM
  3. Merge Data from rows which have a column that matches.
    By kurost in forum Excel Programming / VBA / Macros
    Replies: 16
    Last Post: 03-10-2010, 10:59 AM
  4. For n rows, determine if sum of column values matches criterion
    By SKAh in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-19-2010, 01:08 PM
  5. Replies: 16
    Last Post: 02-09-2009, 07:29 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