Forum Discussion
Building a path based of column data in Power Query
- 9 years ago
Hey,
you can use the function CONCATENATEX(...) to combine values from different rows in one cell.
Here I describe this approach:
https://community.powerbi.com/t5/Desktop/Item-Mix-Visualization/td-p/208161/page/2
If this is not what you're are looking for, please provide easily accessible data (e.g. copy data from excel and paste into the code window)
Hope this helps
- 9 years ago
Prerequisite: column OtherData is in text format.
I used option "Group By" with operation "All Rows" and adjusted the code to have the resulting tables (1 per ID) sorted by DateTime, and OtherData combined to 1 CSV string.
Edit: "1 table per ID" is during the Group By operation. The end result is 1 table in total.
let Source = Table1, #"Grouped Rows" = Table.Group(Source, {"ID"}, {{"data", each Text.Combine(Table.Sort(_, "DateTime")[OtherData],","), type text}}) in #"Grouped Rows"Not sure if this will perform well, with 7 million rows...
Prerequisite: column OtherData is in text format.
I used option "Group By" with operation "All Rows" and adjusted the code to have the resulting tables (1 per ID) sorted by DateTime, and OtherData combined to 1 CSV string.
Edit: "1 table per ID" is during the Group By operation. The end result is 1 table in total.
let
Source = Table1,
#"Grouped Rows" = Table.Group(Source, {"ID"}, {{"data", each Text.Combine(Table.Sort(_, "DateTime")[OtherData],","), type text}})
in
#"Grouped Rows"
Not sure if this will perform well, with 7 million rows...
- MrTD9 years agoFrequent Visitor
Thanks this is what I needed!