Forum Discussion
Mic1979
Post Partisan
1 year agoCells Offset
Dear all, I need to shift the cells on the right in my workload. The idea is this: 1. I need to check what stored is in the column "Name". 2. If in the cells of the column "Name" I have the...
- 1 year ago
OffsetLabour = ((cols) => Table.SplitColumn( Table.CombineColumns( #"Changed Type1", cols, (x) => if Text.Contains(x{0}, "Labour") then {x{0}, x{2}, x{1}} else x, "combined" ), "combined", (x) => x, cols ))({"Name", "Part Number", "Labour Cost (MATURE)"})
slorin
Super User
1 year agoHi Mic1979
...
OffsetLabour1 = Table.ReplaceValue(#"Changed Type1", each Text.Contains([Name],"Labour"), each [#"Part Number"],
(actual, test, new) => if test then new else actual, {"Labour Cost (MATURE)"}),
OffsetLabour2 = Table.ReplaceValue(OffsetLabour1, each Text.Contains([Name],"Labour"), null,
(actual, test, new) => if test then new else actual, {"Part Number"})
...
Stéphane