Hi Alteryx Gurus,
I am very new beginner with Alteryx... and now I am trying to build a user case.
I have a challenge time to convert a date field, the data is shown as " 01-JAN-2017" and I need to convert it into normal date format.
I tried DateTimeFormat([GL_DATE],"%m%d%y") and DateTimeParse.. Both seems not work, and returns null values.
Anyone could kindly provide some guidance on this issue?
Any help is appreciated very much.
Thank you,
Flora
Solved! Go to Solution.
You'll need to define a new field as DATE. Your incoming "date" field is being read in as a STRING.
DateTimeParse([GL_DATE],"%d-%b-%Y")
Cheers,
Mark
Hi Mark,
This works perfectly! Thanks a lot! :)
Flora
My pleasure! Enjoy :)
Hi Mike,
May I ask a further question regarding the use of DateTimeParse ?
So what do I exactly to put in the " ", should it be the format of the existing field, in this case [GL_Date] or the output format I want?
I also find out there is another function int Altyerx called "DateTime" under Parse. Will this function also help me to solve the problem? just wondering.
So grateful for your knowledge.
Thank you,
Flora
Hi again @florayaoyao,
I look up the codes for formatting dates here:
https://help.alteryx.com/11.0/index.htm#Reference/DateTimeFunctions.htm
I'm not sure what " " is....
DateTimeParse([GL_DATE],"%d-%b-%Y")
Can you help to clarify?
Thanks,
Mark
Hi Mark,
The link actually answers my questions.
Thank you so much~
and you have a wonderful day !
Flora