Hi there,
I am trying to concert som data into a date-datatype, but for some reason, the conversion changes the format.
It is a excel file that bring in the data as string, and the format of the date is dd.mm.yyyy. When I covert the data into a date-datatype, it changes the order, and returns yyyy-dd-mm.
I used the formula tool with this formula: DateTimeParse([Dat],"%d.%m.%y")
Thanks in advance
Solved! Go to Solution.
EDIT : Hi @ohruud - I read your question wrong when I responded a minute ago, I'll check it out and reply if someone else doesn't before I get back to it. Apologies for the false start!
The DateTime data type in Alteryx will always store the date in the YYYYMMDD format.
If you want it in another format, you can convert it to a string with the DateTimeFormat function, which outputs a String data type.
Chris
Ah, okei. So yyyy-mm-dd is the only format alteryx allows in terms of doing calculations ?
That is correct. It is very common for people to change their date format at the end of a workflow for familiarity in reporting outputs.
I see. Thank you so much 🙂
Hi Blake,
I just have one more question
When i used the DateTimeParse formul, the dates came out correctly. However, when i used the datetime tool and custom-fitted the incomming string to be dd.mm.yyyy, the result came out wrong.
I had for example the date 11.12.2000, and it came out as 2000-01-11 00:12:00 instead of 2000-12-11. Dont know why.
you have to use MM instead of mm.
mm is used for Minutes
MM is used for Months
Thanks 🙂
the YYYYMMDD format, is the default format for Alteryx?