I have a workflow that analyzes dates input as strings, and I'd like to output them as dates.
The DateTime tool in the Parse section works well, but it outputs as ISO format (YYYY-MM-DD). The consumers of the output have asked for "American" output, MM-DD-YYYY.
This is simple enough, with a Formula tool and the DateTimeFormat function. However, if I use this, I apparently cannot "re-use" the same field name as the output from the DateTime tool. When attempting to do so, I get an error saying that it is an invalid date.
See attached workflow for a very simple example. Am I missing something, or is this a potential bug? I would prefer not to add additional columns of data in the workflow, and this issue appears to require two additional columns (one from the DateTime tool, and then another to actually be able to store the reformatted output of the DateTime tool).
Solved! Go to Solution.
In Alteryx, a date will always be YYYY-MM-DD, if you want it in American format it would have to be a string and not a date.
So that does mean 1 more column, but you'd remove the (proper) date field as well so the consumers wouldn't see a change at all right ?
This should help :)
Ah, I did not know that DateTimeParse works with strings! This will make things a lot easier.