Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Formatting of date

Belletmns
8 - Asteroid

Hi All,

 

I need to format below dates to "dd-mm-yyyy" (example in should be column). When using datetimetool I'm having error that the date in the below is not in valid format.

 

Belletmns_0-1600166188505.png

 

Thanks!

6 REPLIES 6
grazitti_sapna
17 - Castor

Hi @Belletmns , try this.

 

Formula

DatetimeFOrmat(DateTimeParse(Date,"%m/%d/%Y"),"%d-%m-%Y")

 

grazitti_sapna_0-1600167059689.png

 

Thanks.

Sapna Gupta
Himanshu_1984
8 - Asteroid

you can use the datetime formatting option in formula tool  "DateTimeFormat([DateTime_Out], "%d-%m-%Y")" but it will be in a string format only because Alteryx's default date format is "YYYY-MM-DD"

 

Regards,

Himanshu

ttiverson98
5 - Atom

I have the following data and need it to be read as a date.  I changed the Value Date to "date" under type, but it still comes up as Null.

 

Thanks, Todd

ttiverson98_0-1619528908633.png

 

Luke_C
17 - Castor

Hi @ttiverson98 

 

You can use the DateTime or formula tool to convert it to a date. Alteryx only reads dates in yyyy-mm-dd format, simply updating the data type won't work because your data is not in the correct format. See attached, both tools are essentially doing the same thing, creating a date field by telling alteryx the data is structured as %Y%m%d.

 

More info on date functions: https://help.alteryx.com/current/designer/datetime-functions

 

Luke_C_0-1619529532638.png

 

Emil_Kos
17 - Castor
17 - Castor

Hi @ttiverson98,

 

You need to tell Alteryx how to read this date. I have prepared a workflow for you!

ttiverson98
5 - Atom

Thank You, works perfectly.

Labels