We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Parsing and then convert string to date

MikeFrancis1959
8 - Asteroid

I have a date column for ship dates but many times it will not contain a date but will show "ETA 05/26"  when they anticipate the material will ship and what I am trying to do is parse this into 2 columns and then add "/2023" to the column and then convert to a date. I can parse the date and then add "/2023" but when I try to convert to a date it comes out 2023-01-26 and I don't know why it shows January instead of May, can someone look at point out where I went wrong? 

Thanks,

Mike

 

 

 Field1         Field11        Field12                   add year                      Date
ETA 05/26   ETA            05/26                        05/26/2023             2023-01-26
5 REPLIES 5
Dina
9 - Comet

This should work. 

  DateTimeParse([Field12]+"/2023","%m/%d/%y")

 

 

binuacs
21 - Polaris

@MikeFrancis1959 You can try the below formula

 

DateTimeParse(toString(DateTimeYear(DateTimeToday()))+Replace([Field1],'ETA',''),'%Y%m/%d')

 

binuacs_0-1684957120596.png

 

 

cjaneczko
13 - Pulsar

Change your mm to MM in the DateTimeConverstion. mm is Minutes. MM is Months.

MikeFrancis1959
8 - Asteroid

Thank you very much!

Mike

MikeFrancis1959
8 - Asteroid

Thank you very much, you have helped me in the past and I keep learning so much with everyone's help!

Mike

Labels
Top Solution Authors