The documentation here: https://msdn.microsoft.com/en-us/library/mt674921.aspx Says that DATE(2009,1,1) is a valid value, but this returns an error. VAR Holidays = DATATABLE("Date",DATETI...
Anonymous
4 years agoNot applicable
Hi,
v-qiuyu-msft , you can use DATATABLE function to create a date column as well. You just need to enter the date in a specific format.
I could actually define a column with DATETIME datatype, where I entered the date as "YYYY-MM-DD" and it worked perfectly. You can later change it from datetime to just date format. So, here is a part of my code:
DATATABLE(
"Accounting unit",INTEGER,
"Location",STRING,
"Opening date",DATETIME,
"Closing date",DATETIME,
{
{1111,"Location 1","2010-11-1",},
{2222,"Location 2","2010-11-1",}
}
)
Cheers