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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

M Type source load from datalake converting date to US format when it can and rest to UK format

Power BI data source from datalake 

eg expression below

ckdev_0-1726184603795.png

The data source date are in the uk format dd/MM/yyyy
When I process the cube for some reason it will convert the dates to US format if it can and leave the rest to UK format.
So we end up with mixed date formats in the cube. Which is incorrect.
Image below to demostrate.
2nd and 5th row it was swapped to MM/dd/yyyy while the 3rd row is dd/MM/yyyy. 
Column one is the original date in text so we can compare while column two is the processed date. 

ckdev_1-1726185166329.png

But when we get data from sql server this issue doesnt occur. Image the correct behaviour getting from sql server. 

ckdev_2-1726185392159.png

 

So concluding this is the issue with the DeltaLake.Table(TableSource) function in m type. Anyone else having this issue ? 

 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,
According to your description, there is mixed formatting when using M code to get the table from DataLake. The first thing we need to make clear is that the final data retrieved in the power query should be in the same format for each column, so your “mixed columns” are all recognized as US format, if you want them all to be in UK format, you can do a format conversion in m code

Source:{
"Type": "m",
"expression": [
	"let",
	"	Source = AzureStorage.DataLake(...)",
	"	TTableSource" = Source{...}",
	"	ToDelta" = DaltaLake.Table(),
	"	ConvertedDates = Table.TransformColumns(ToDelta, {{"DateColumn", each Date.FromText(_, "en-GB"), type date}})",
	"in",
	"	ConvertedDates"
	]
}

 

Best regards,
Albert He


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

1 REPLY 1
Anonymous
Not applicable

Hi @Anonymous ,
According to your description, there is mixed formatting when using M code to get the table from DataLake. The first thing we need to make clear is that the final data retrieved in the power query should be in the same format for each column, so your “mixed columns” are all recognized as US format, if you want them all to be in UK format, you can do a format conversion in m code

Source:{
"Type": "m",
"expression": [
	"let",
	"	Source = AzureStorage.DataLake(...)",
	"	TTableSource" = Source{...}",
	"	ToDelta" = DaltaLake.Table(),
	"	ConvertedDates = Table.TransformColumns(ToDelta, {{"DateColumn", each Date.FromText(_, "en-GB"), type date}})",
	"in",
	"	ConvertedDates"
	]
}

 

Best regards,
Albert He


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

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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