Alteryx Designer Desktop Discussions

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

DateTime_Out: Day of month value is out of range

DerekR
5 - Atom

Hello,

 

I am trying to convert an Input String of d/-Mon.-yy to a Date/Time.  It’s working for double digit days of the month (16-Feb-16), showing Null for single digit days (2-Mar-16).

 

I’ve been through a number of posts, but still having trouble.  Any help would be appreciated. 

 

Thank you! 

3 REPLIES 3
MSalvage
11 - Bolide

@DerekR, 

 

My coworker @TylerN ran into this same issue a few months back. The problem being Alteryx is expecting 04 instead of 4 for the day. In the end he ended up parsing his date and writing a formula something like:

 

IF ToNumber([DAY]) < 10    --DAY being your parsed day

THEN PadLeft([DAY], 1, 0)

ELSE [DAY]

ENDIF

 

and then concatenating it all back together and running it again. Hope this helps.

 

Good Luck, 

MSalvage

 

 

Kanderson
10 - Fireball

You should be able to use the date time parse function. I tested with the following and everything looks good. I have attached a sample file. Documentation on this function can be found here - http://downloads.alteryx.com/Alteryx8.6.2/WebHelp/Reference/DateTimeFunctions.htm

 

 

DateTimeParse([Date],"%d-%b-%y")

DerekR
5 - Atom

Thanks, this did not work on 10.6, but I updated to 11 and it did exactly what I needed.  Thank you for the help!!!

Labels