Forum Discussion
ClemFandango
3 years agoAdvocate II
Importing column and converting into date
Hello PowerBI community, I am in desperate need of help. I have spent about 2 weeks trying to do this and failed miserably. All I need to do is convert a column into a recognisable date format. Th...
- 3 years ago
Hi ClemFandango ,
Add a new custom column with the following calculation:
let xDate = Text.BeforeDelimiter([Source.Name], ".") in Text.Combine( { "20" & Text.End(xDate, 2), Text.Range(xDate, 2, 2), Text.Start(xDate, 2) }, "-" )This outputs as text in ISO format, allowing you to convert to any type/locale you need afterwards.
Example output:
Pete
BA_Pete
3 years agoSuper User
Hi ClemFandango ,
Add a new custom column with the following calculation:
let xDate = Text.BeforeDelimiter([Source.Name], ".") in
Text.Combine(
{
"20" & Text.End(xDate, 2),
Text.Range(xDate, 2, 2),
Text.Start(xDate, 2)
},
"-"
)
This outputs as text in ISO format, allowing you to convert to any type/locale you need afterwards.
Example output:
Pete
ClemFandango
3 years agoAdvocate II
Thank you so much. You have no idea how long i previously spent on this. Your suggestion works wonderfully.