Forum Discussion
EDO_01_1789
4 years agoHelper I
previous date
Hello, I would like to create a New column that will allow me to have the time of the previous validator. here is the result I would like to have. in my table there are between 5 and ...
- 4 years ago
Hi EDO_01_1789,
Something like this?
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjbUNzTSN7Q0N1eK1QFzDYxBXAsI10DfwAyVa4nEhekFcmMB", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [#"Validator Date" = _t]), #"Changed Type" = Table.TransformColumnTypes(Source,{{"Validator Date", type date}}), Custom1 = Table.FromColumns(Table.ToColumns(#"Changed Type") & { {""} & List.RemoveLastN(#"Changed Type"[Validator Date],1)}, Value.Type(Table.AddColumn(#"Changed Type", "Previous Date", each null, type date))) in Custom1N.B. you will need to use GroupBy to get this applied to the reviewed files in batches.
Cheers,
John
jbwtp
4 years agoMemorable Member
Hi EDO_01_1789,
Something like this?
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjbUNzTSN7Q0N1eK1QFzDYxBXAsI10DfwAyVa4nEhekFcmMB", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [#"Validator Date" = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Validator Date", type date}}),
Custom1 = Table.FromColumns(Table.ToColumns(#"Changed Type") & { {""} & List.RemoveLastN(#"Changed Type"[Validator Date],1)}, Value.Type(Table.AddColumn(#"Changed Type", "Previous Date", each null, type date)))
in
Custom1
N.B. you will need to use GroupBy to get this applied to the reviewed files in batches.
Cheers,
John