Alteryx Designer Desktop Discussions

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

Convert text date to date

mszpot89
9 - Comet

 

Here are my sample dates

 

Monday, November 5, 2018 8:38 AM
Wednesday, October 10, 2018 2:51 PM

 

How can I get them converted into below format

2018-11-05
2018-10-22

 

3 REPLIES 3
CharlieS
17 - Castor
17 - Castor

Here's the formula used to parse that format:

 

DateTimeParse([Input],"%A, %B %d, %Y %I:%M %p")

 

I recommend keeping this page bookmarked:

https://help.alteryx.com/9.5/Reference/DateTimeFunctions.htm

Thableaus
17 - Castor
17 - Castor

Hi @mszpot89

 

 

Sorry I had not seen Charlie's reply.

I'd add the DateTimeFormat function to remove the time.

DateTimeFormat(DateTimeParse([Field1], "%A, %B %d, %Y %I:%M %p"),"%Y-%m-%d")

 

Cheers,

mszpot89
9 - Comet

@Thableaus - I modified @CharlieS solution also to skip time.

 

DateTimeParse([Date of query receive],"%A, %B %d, %Y")

 

Labels