Forum Discussion
zraptor
3 years agoFrequent Visitor
Grouping rows by like values and combining subsequent columns
Hello! I have a problem that I am sure is probably pretty basic but my brain has quit functioning and I can't get past this. I have a table with two columns. An ID column and a Service column. Sh...
- 3 years ago
Hi,
This M code works
let Source = Excel.CurrentWorkbook(){[Name="Data"]}[Content], #"Changed Type" = Table.TransformColumnTypes(Source,{{"Service", type text}}), #"Grouped Rows" = Table.Group(#"Changed Type", {"ID"}, {{"All services", each Text.Combine([Service], ", ")}}) in #"Grouped Rows"Hope this helps.
Ashish_Mathur
Super User
3 years agoHi,
This M code works
let
Source = Excel.CurrentWorkbook(){[Name="Data"]}[Content],
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Service", type text}}),
#"Grouped Rows" = Table.Group(#"Changed Type", {"ID"}, {{"All services", each Text.Combine([Service], ", ")}})
in
#"Grouped Rows"
Hope this helps.
- zraptor3 years agoFrequent Visitor
Perfect! Thank you so much!
- Ashish_Mathur3 years ago
Super User
You are welcome.