Concatenate based on cell value

thedeadzeds

Active Member
Joined
Aug 16, 2011
Messages
442
Office Version
  1. 365
Platform
  1. Windows
Hi Guys

I have a table with shows comments (or notes) for each No in column A. I need to be able to get all the comments in one cell. An example of this would be the 'Notes concate' column. As you can see, No 1 as 4 comments but these appear on different rows. Is there a way to concatenate all of these comments in to one cell as per the example in Notes concate column?

Thanks

NoRef1Ref2Ref3Ref4Ref5Ref6Ref7Ref8Ref9Ref10Ref11Ref12Ref13NotesNotes concate
1ABC24045Red149000013001515250Comment 1Comment 1, Comment 2, Comment 3, Comment 4
0000000000Comment 2
150150000000Comment 3
1500001200150Comment 4
0000000000Comment 5
2ABCD24045Green149000013001515250Comment 1Comment 1
3ABCDE24045Orange149000013001515250Comment 1Comment 1
4ABCDEF24045Blue149000013001515250Comment 1Comment 1
5ABCDEFG24046Blue149000013001515250Comment 1Comment 1, Comment 2, Comment 3
0000000000Comment 2
0000000000Comment 3
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
This is how I would do it based on the example provided.
Book1
ABCDEFGHIJKLMNOP
1NoRef1Ref2Ref3Ref4Ref5Ref6Ref7Ref8Ref9Ref10Ref11Ref12Ref13NotesNotes concate
21ABC24045Red149000013001515250Comment 1Comment 1, Comment 2, Comment 3, Comment 4, Comment 5
30000000000Comment 2 
4150150000000Comment 3 
51500001200150Comment 4 
60000000000Comment 5 
72ABCD24045Green149000013001515250Comment 1Comment 1
83ABCDE24045Orange149000013001515250Comment 1Comment 1
94ABCDEF24045Blue149000013001515250Comment 1Comment 1
105ABCDEFG24046Blue149000013001515250Comment 1Comment 1, Comment 2, Comment 3
110000000000Comment 2 
120000000000Comment 3 
Sheet6
Cell Formulas
RangeFormula
P2:P12P2=IF(A2="","",TEXTJOIN(", ",1,O2:INDEX(O:O,IFERROR(MATCH(A2+1,A:A,0)-1,MATCH("zzz",O:O)))))
 
Upvote 0

Forum statistics

Threads
1,215,137
Messages
6,123,254
Members
449,093
Latest member
Vincent Khandagale

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top