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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
admin11
Memorable Member
Memorable Member

How to change the Date Format from MM/DD/YYYYY to DD/MM/YYYY ?

Hi All

 

My SALES_I table date format is MM/DD/YYYY

admin11_2-1640514900400.png

 

My SALES_T table date format is DD/MM/YYYY

admin11_1-1640514827807.png

 

My i know how to change the SALES_I table date format is MM/DD/YYYY to DD/MM/YYYY ?

 

My PBI file :-

https://www.dropbox.com/s/27r10hc73bijui7/PBTI_V050.pbix?dl=0

 

Paul

1 ACCEPTED SOLUTION
negi007
Community Champion
Community Champion

@admin11 in this case I can see that your data is in date format(MM/DD/YYYY) already in second table so you need to change the date format 

 

However, your data in first table is not in the date format(dd/mm/YYYY) so you wont be able to perform date calc/time inteligenice calc so in powerquery window you can simply change the format like below

 

this is the format you have 

negi007_0-1640521358893.png

 

right click on your date column, you will get option to add column from examples. you type the first two values in the format you want to have the data. power query will format the data for rest of the records

 

negi007_1-1640521526073.png

 

then you can change the format the data to date format

negi007_2-1640521619152.png

 

now you data is in the date format in both the tables.




Did I answer your question? Mark my post as a solution!
Appreciate your Kudos



Proud to be a Super User!


Follow me on linkedin

View solution in original post

4 REPLIES 4
bcdobbs
Super User
Super User

In the background power bi imports dates as integers. You then can choose the display format:

bcdobbs_0-1640516860272.png

or in the model view you can set custom formats:

bcdobbs_1-1640516914721.png

 



Ben Dobbs

LinkedIn | Twitter | Blog

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!

@bcdobbs 

Thank you for sharing. I have try to set the date format as per your image, it does not change . 

Issue is when i try to append both table into 1 , the date format have 2 different type. ( I have also try to use PQ to change the field to date , many row get error , I also try to change by change type with Locale. it also does not work.

admin11_0-1640517495764.png

 

negi007
Community Champion
Community Champion

@admin11 in this case I can see that your data is in date format(MM/DD/YYYY) already in second table so you need to change the date format 

 

However, your data in first table is not in the date format(dd/mm/YYYY) so you wont be able to perform date calc/time inteligenice calc so in powerquery window you can simply change the format like below

 

this is the format you have 

negi007_0-1640521358893.png

 

right click on your date column, you will get option to add column from examples. you type the first two values in the format you want to have the data. power query will format the data for rest of the records

 

negi007_1-1640521526073.png

 

then you can change the format the data to date format

negi007_2-1640521619152.png

 

now you data is in the date format in both the tables.




Did I answer your question? Mark my post as a solution!
Appreciate your Kudos



Proud to be a Super User!


Follow me on linkedin

@negi007 

Thank you very much for your sharing . Your explanation is very clear. i learn one more new thing,

Paul

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.