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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Anonymous
Not applicable

Changing date format in Power Query Editor

Hi Community..!!

I wanted to change date format (DD-MM-YYYY) into (YYYY-MM-DD) in Power Query Editor

 

ppatil_0-1637068585965.png

ppatil_1-1637068627067.png

I want above dates in the 2018-06-01 in Power Query Editor.

Please help me out to do this..!!

 

1 ACCEPTED SOLUTION
Icey
Community Support
Community Support

Hi @Anonymous ,

 


 

I wanted to change date format (DD-MM-YYYY) into (YYYY-MM-DD) in Power Query Editor

 


Why do you want to change date format from DD-MM-YYYY to YYYY-MM-DD? 

 

If you want to keep the data type as "Date", it is no need to manually change it in Power Query Editor. It is based on your local machine's date formate. 

 

date format 1.PNGdate format 2.PNG

 

You can change it in Power BI Desktop later.

Icey_0-1637305554901.png

 

If you want to keep the data type as text and since your date column has changed to "Date" type, create a custom column like this:

Text.From(Date.Year([Date])) & "-" & Text.From(Date.Month([Date])) & "-" & Text.From(Date.Day([Date]))

Icey_1-1637305927682.png

 

 

Best Regards,

Icey

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
Icey
Community Support
Community Support

Hi @Anonymous ,

 


 

I wanted to change date format (DD-MM-YYYY) into (YYYY-MM-DD) in Power Query Editor

 


Why do you want to change date format from DD-MM-YYYY to YYYY-MM-DD? 

 

If you want to keep the data type as "Date", it is no need to manually change it in Power Query Editor. It is based on your local machine's date formate. 

 

date format 1.PNGdate format 2.PNG

 

You can change it in Power BI Desktop later.

Icey_0-1637305554901.png

 

If you want to keep the data type as text and since your date column has changed to "Date" type, create a custom column like this:

Text.From(Date.Year([Date])) & "-" & Text.From(Date.Month([Date])) & "-" & Text.From(Date.Day([Date]))

Icey_1-1637305927682.png

 

 

Best Regards,

Icey

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

@Icey Thank You So much..!!

Anonymous
Not applicable

How to create new column in Power Query Editor ?

@amitchandak 

amitchandak
Super User
Super User

@Anonymous , You can create a new column as text or date

 

Text.End([Month]) & "-" & Text.Middle([Month],3,2) & "-" Text.Start([Month],2)

 

#date(Text.End([Month]) , Text.Middle([Month],3,2) , Text.Start([Month],2))

 

in case if date you can filter data > 2018

 

in case text > 2018-00-00

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

I have used below formula 

ppatil_0-1637146444240.png

But its showing error like this 

ppatil_1-1637146514327.pngppatil_2-1637146535126.png

 

Helpful resources

Announcements
June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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