Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
eKat
Frequent Visitor

How do I convert text column to a custom "yyyy-mm-dd" format

Hi there,

 

I have Power BI linked to a folder with Excel files, in which date appears in a custom text format as "28-Feb-20". When I load the files to Power BI, it automatically recognizes the date columns as Short Date turning February 28, 2020 into 20 February 2028. To avoid this, I have disabled auto-recognition of the format. However, I still need to convert the custom text into a date and when I try using FORMAT function it gives me an error saying FORMAT isn't recognized or spelled correctly.

PowerBi Date Format.PNG

 

I also tried adding VALUE function to extract value from [ORDER DATE] and it didn't work. 

 

Any ideas on how to go about it?

 

Thanking you in advance!

 

Katherine

1 ACCEPTED SOLUTION

Hi @eKat ,

 

Changing local shoud help you in your scenario. Please refer to the steps as the screen shots below.

3.png

1.PNG2.PNG

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

View solution in original post

3 REPLIES 3
Greg_Deckler
Community Champion
Community Champion

FORMAT is a DAX function, you are writing M code.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Thank you, Greg.

 

Do you know by any chance which M script to write to convert custom text format of "dd-mmm-yyyy" to  "yyyy-mm-dd'? 🙂 

 

Hi @eKat ,

 

Changing local shoud help you in your scenario. Please refer to the steps as the screen shots below.

3.png

1.PNG2.PNG

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors