+ Reply to Thread
Results 1 to 14 of 14

How to merge rows by the value of the cells in the column A

  1. #1
    Registered User
    Join Date
    05-20-2024
    Location
    Finland
    MS-Off Ver
    Microsoft 365 MSO Version 2404 64-bit
    Posts
    6

    How to merge rows by the value of the cells in the column A

    Hello!
    I have a problem. I have Excel sheet with almost 100k rows. My task is to merge rows with same ID (In cells in column A). I have information in B, C, D, E and F cells. My goal would be a sheet where the data of these rows with a same value in cell A are on same row conjucated in their own cells. I'm newbie to Excel and I'm not even sure if this is possible.
    Attached Files Attached Files
    Last edited by Toikki; 05-20-2024 at 02:36 AM.

  2. #2
    Registered User
    Join Date
    05-20-2024
    Location
    Finland
    MS-Off Ver
    Microsoft 365 MSO Version 2404 64-bit
    Posts
    6

    Re: How to merge rows by the value of the cells in the column A

    I'd say there is no more than max 10 rows per unigue colum A value. If this helps at all

  3. #3
    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. 2407 (Windows 11 23H2 64-bit)
    Posts
    83,150

    Re: How to merge rows by the value of the cells in the column A

    Administrative Note:

    Welcome to the forum.

    By 'bumping' your thread, you've removed it from the unanswered threads list - not a good idea, for future reference.

    Is your forum profile showing the Excel PRODUCT that you need this to work for?

    Members will tailor the solutions they offer to the Office PRODUCT (Excel, NOT Windows) that you have. Please check that your forum profile is up-to-date in this respect. If you aren't sure, in Excel go to File | Account and report what it says below the MS logo at the top of that page. If your product is for Mac, please also state this.

    The three most recent Excel products are Excel 2019, Excel 2021 and MS365 - if you are using MS365, please give this name along with the version number in your profile (e.g. MS365 Version 2306). This is in the About Excel section further down the Account page.

    Thanks.
    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.

  4. #4
    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. 2407 (Windows 11 23H2 64-bit)
    Posts
    83,150

    Re: How to merge rows by the value of the cells in the column A

    I don't see where you have mocked up your expected results for this sample data - please do this manually to show what we are aiming for.

  5. #5
    Registered User
    Join Date
    05-20-2024
    Location
    Finland
    MS-Off Ver
    Microsoft 365 MSO Version 2404 64-bit
    Posts
    6

    Re: How to merge rows by the value of the cells in the column A

    Hello. I updated my profile to match my microsoft version. Now that I have accidentally 'bumped' my post, is there any way to get more visibility for it again?

  6. #6
    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. 2407 (Windows 11 23H2 64-bit)
    Posts
    83,150

    Re: How to merge rows by the value of the cells in the column A

    No need - because I have now started interacting with you.

    Please provide the updated sample workbook requested above.

  7. #7
    Registered User
    Join Date
    05-20-2024
    Location
    Finland
    MS-Off Ver
    Microsoft 365 MSO Version 2404 64-bit
    Posts
    6

    Re: How to merge rows by the value of the cells in the column A

    Sorry. Damn I'm ashamed. :D Sorry. Here is the updated Excel with desired result included to file.Example_file.xlsx

  8. #8
    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. 2407 (Windows 11 23H2 64-bit)
    Posts
    83,150

    Re: How to merge rows by the value of the cells in the column A

    No need to be ashamed!!!

    I'll have another look now.

  9. #9
    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. 2407 (Windows 11 23H2 64-bit)
    Posts
    83,150

    Re: How to merge rows by the value of the cells in the column A

    OK - may I ask what the purpose of having the data in the new layout is? Because it is NOT practical data layout. What you have already is MUCH better for subsequent data analysis, and the problem with side-by-side layouts is that you end up doing a lot of scrolling.

    Before we assist, take a moment to consider whether this is actually a good idea - I think not, personally.

  10. #10
    Registered User
    Join Date
    05-20-2024
    Location
    Finland
    MS-Off Ver
    Microsoft 365 MSO Version 2404 64-bit
    Posts
    6

    Re: How to merge rows by the value of the cells in the column A

    I agree with you. It would be a much more clear to view this data as the way it is. These row's are parts of installations and for some reason customer wants them to be on same row.

  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. 2407 (Windows 11 23H2 64-bit)
    Posts
    83,150

    Re: How to merge rows by the value of the cells in the column A

    OK - here's how:

    =IFNA(HSTACK(UNIQUE(A2:A17),DROP(REDUCE(0,UNIQUE(A2:A17),LAMBDA(x,r,VSTACK(x,TOROW(FILTER(B2:F17,A2:A17=r),,0)))),1)),"")

    The customer isn't always right and, sometimes, needs educating.
    Attached Files Attached Files

  12. #12
    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. 2407 (Windows 11 23H2 64-bit)
    Posts
    83,150

    Re: How to merge rows by the value of the cells in the column A

    Here's a version that will deal with more rows:

    =LET(u,TOCOL(UNIQUE(A2:A1000),1),IFNA(HSTACK(u,DROP(REDUCE(0,u,LAMBDA(x,r,VSTACK(x,TOROW(FILTER(B2:F1000,A2:A1000=r),,0)))),1)),""))

    Adjust the ranges in RED to suit your real data.

    If that takes care of your original question, please choose Thread Tools from the menu link above and mark this thread as SOLVED. You can also access the SOLVED tag by editing the opening post and choosing SOLVED from the drop-down to the left of the title box.

    Also, if you have not already done so, remember that you can reward anyone who offered you help towards a solution for your issue by clicking the small star icon (* Add Reputation) located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of each of those who offered help.
    Attached Files Attached Files

  13. #13
    Registered User
    Join Date
    05-20-2024
    Location
    Finland
    MS-Off Ver
    Microsoft 365 MSO Version 2404 64-bit
    Posts
    6

    Re: How to merge rows by the value of the cells in the column A

    Yu are my savior! Thanks a lot. I'm very grateful and impressed.

  14. #14
    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. 2407 (Windows 11 23H2 64-bit)
    Posts
    83,150

    Re: How to merge rows by the value of the cells in the column A

    You're welcome.

    Let me know if you need it explaining at all.

+ 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] Merge irregular rows data into 1 column and find the next row based on another column
    By ec4excel in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-29-2023, 11:42 AM
  2. Merge Cell Contents from multiple cells/rows based on value in column A
    By vikrampnz in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 12-14-2018, 07:32 AM
  3. Merge cells in a column, using a column as a reference to merge them
    By mattybNSI126 in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 02-20-2018, 06:05 PM
  4. Replies: 4
    Last Post: 09-15-2014, 06:01 AM
  5. Replies: 2
    Last Post: 04-08-2014, 04:44 AM
  6. Remove duplicates on column A and merge rows in column B
    By JJcool in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-29-2012, 05:41 PM
  7. Auto Sum for Rows and Column & Merge Cells in a row
    By sravanthi.boggaram in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-10-2011, 02:53 AM

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