Forum Discussion
Date for all rows
Does your filename include the date? If so, it might just be easier to parse it out of that and convert to a date. If not, you may be able to use this shift and fill technique to get the date on every row.
https://www.youtube.com/watch?v=VEjsze31MPU
Also, if your refresh slows down, it is also possible to leverage incremental refresh in your published dataset (so you are not reprocessing every file ever time).
https://www.youtube.com/watch?v=IVMdg16yBKE
Pat
My file name includes the date, but how do i parse it out and convert it to a date?
- m_dekorte3 years ago
Resident Rockstar
Hi Anonymous,
Does it have a fixed position in the file name?
And/or can you share a representative example of these file names?
- Anonymous3 years agoNot applicable
It looks like this. The data is very messy, i have to clean it up. But this is for the example
- Anonymous3 years agoNot applicable
It looks like this. The data is very messy, i have to clean it up. But this is for the example
- Anonymous3 years agoNot applicable
I fixed it, thanks for the help!
- m_dekorte3 years ago
Resident Rockstar
Hi Anonymous
Give something like this a go
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WCijKTylNLslMLS5JLMksBjKyU/MU8hITixRSK5JTcxSMDIyMdQ1MdQ1MdA3MdQ0MdI0M9SpyiiuUYnVI0W1KkW4zdN2xAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Name = _t]), AddDate = Table.AddColumn(Source, "Date", each [ v = Splitter.SplitTextByCharacterTransition( {"A".."z", " "}, {"0".."9"})([Name]){1}?, r = try Date.From( Text.Start(v, 10), "nl-NL") otherwise null ][r], type date ) in AddDatePs. If this helps solve your query please mark this post as Solution, thanks!