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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

0

localnow() M function is different in PowerBI than is documented

https://msdn.microsoft.com/en-us/library/mt253492.aspx

 

Per this site, the M function should return

DateTime.LocalNow()equals 2013-03-08T14:22:42  

in that format - but in PowerBI Query Editor, the month and day are returning single digit values for 1-9. This makes it very difficult to create functions that rely on aligning a datekey to an existing table based on the current date when refreshing.

Status: Delivered
Comments
v-haibl-msft
Employee

@AlexDantin

 

This is not related to Power BI but Power Query itself. If we use Query Editor in Excel, we will get the same result as below.

 

localnow() M function is different in PowerBI than is documented_1.jpg 

 

Best Regards,

Herbert

AlexDantin
Helper I

Thank you for the clarification.

Vicky_Song
Impactful Individual
Status changed to: Delivered
 
AlexDantin
Helper I

What does Delivered mean? Has this problem been delivered to the Power Query Team?

v-haibl-msft
Employee

@AlexDantin

 

Since it is not related to Power BI but Power Query, you need to post this problem in Power Query forum.

 

Best Regards,

Herbert