{"id":11,"date":"2016-08-01T11:34:51","date_gmt":"2016-08-01T11:34:51","guid":{"rendered":"http:\/\/coding.agust.org\/?p=11"},"modified":"2016-11-25T15:24:00","modified_gmt":"2016-11-25T15:24:00","slug":"power-query-group-by-one-column-and-concatenate-string-values-of-another-column","status":"publish","type":"post","link":"https:\/\/coding.agust.org\/index.php\/2016\/08\/01\/power-query-group-by-one-column-and-concatenate-string-values-of-another-column\/","title":{"rendered":"Power Query group by one column and concatenate string values of another column"},"content":{"rendered":"<div class=\"article-content entry-content\">\n<p>I needed an example of how to\u00a0group by one column and concatenate string values of another column.<\/p>\n<p>Here is what this ended up like:<br \/>\n&#8212;<br \/>\nlet<br \/>\nSource = #table({&#8220;Product&#8221;, &#8220;Customer&#8221;},{{ &#8220;Apples&#8221;,&#8221;Chris&#8221;},{&#8220;Apples&#8221;,&#8221;Fred&#8221;} ,{&#8220;Oranges&#8221;,&#8221;Chris&#8221;}}),<br \/>\nmyCombine = Combiner.CombineTextByDelimiter(&#8220;;&#8221;),<br \/>\n#&#8221;Grouped Rows&#8221; = Table.Group(Source, {&#8220;Product&#8221;}, {{&#8220;Test&#8221;, each myCombine ([Customer]), type text}})<br \/>\nin<br \/>\n#&#8221;Grouped Rows&#8221;<br \/>\n&#8212;<\/p>\n<\/div>\n<div class=\"article-footer\"><\/div>\n","protected":false},"excerpt":{"rendered":"<p>I needed an example of how to\u00a0group by one column and concatenate string values of another column. Here is what this ended up like: &#8212; let Source = #table({&#8220;Product&#8221;, &#8220;Customer&#8221;},{{ &#8220;Apples&#8221;,&#8221;Chris&#8221;},{&#8220;Apples&#8221;,&#8221;Fred&#8221;} ,{&#8220;Oranges&#8221;,&#8221;Chris&#8221;}}), myCombine = Combiner.CombineTextByDelimiter(&#8220;;&#8221;), #&#8221;Grouped Rows&#8221; = Table.Group(Source, {&#8220;Product&#8221;}, {{&#8220;Test&#8221;, each myCombine ([Customer]), type text}}) in #&#8221;Grouped Rows&#8221; &#8212;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-11","post","type-post","status-publish","format-standard","hentry","category-power-query"],"_links":{"self":[{"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/posts\/11","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/comments?post=11"}],"version-history":[{"count":2,"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/posts\/11\/revisions"}],"predecessor-version":[{"id":66,"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/posts\/11\/revisions\/66"}],"wp:attachment":[{"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/media?parent=11"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/categories?post=11"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/coding.agust.org\/index.php\/wp-json\/wp\/v2\/tags?post=11"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}