Forum Discussion
roscas
Helper I
2 years agoShow result in only one row
Good afternoon, I need help with the following case. If anyone could help me, I would appreciate it. I have a table where in the 'request' column there are duplicate values because there are values i...
- 2 years ago
Hi roscas,
Before
After
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjOxMLQwt1DSUfLKL05VCM7NLMkAcqAoVgdZBTZFcBUWBkCub2JRZqKCc0ZiWWoVFlPAauAIRTE2NeimYajBYl1sLAA=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Request = _t, #"Policy Holder" = _t, Item1 = _t, #"Item 12" = _t, #"Item 13" = _t]), // You can probably delete this step. ReplaceBlankToNull = Table.TransformColumns(Source, {}, each if _ = "" then null else _), GroupedRows = Table.Group(ReplaceBlankToNull, {"Request"}, {{"All", each [ a = Table.ColumnNames(_), b = Table.FillUp(Table.FillDown(_, a), a) ][b], type table}}), All = Table.Combine(GroupedRows[All]) in All
dufoq3
Community Champion
2 years agoHi roscas,
Before
After
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjOxMLQwt1DSUfLKL05VCM7NLMkAcqAoVgdZBTZFcBUWBkCub2JRZqKCc0ZiWWoVFlPAauAIRTE2NeimYajBYl1sLAA=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Request = _t, #"Policy Holder" = _t, Item1 = _t, #"Item 12" = _t, #"Item 13" = _t]),
// You can probably delete this step.
ReplaceBlankToNull = Table.TransformColumns(Source, {}, each if _ = "" then null else _),
GroupedRows = Table.Group(ReplaceBlankToNull, {"Request"}, {{"All", each
[ a = Table.ColumnNames(_),
b = Table.FillUp(Table.FillDown(_, a), a)
][b], type table}}),
All = Table.Combine(GroupedRows[All])
in
All