Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Desktop Discussions

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

Date Format Question

MadelineKornack
5 - Atom

I have a data source which lists dates out as strings in the format 'September 2022', 'October 2022', etc. I would like them to be in date format of 12/1/2022. The datetime tool does not have the option for this that I am aware of. Is there a way for me to change variable text to date?

4 REPLIES 4
IraWatt
17 - Castor
17 - Castor

Hey @MadelineKornack,

The First step is to convert the text 'September 2022' to a date data type this can be done with the date time tool or datetimeparse function. Once you have your date data type you can convert it back to text into your desired format 12/1/2022 with the datetime tool or the datetimeformatt function 

IraWatt_0-1668464241828.png

If your interested in learning more about the datetime functions there is a great cheat sheet Blog here: https://community.alteryx.com/t5/Engine-Works/DateTime-Functions-Cheat-Sheet/ba-p/844353

 

Any questions or issues please ask

Ira Watt
Technical Consultant
Watt@Bulien.com 

 

Felipe_Ribeir0
16 - Nebula

Hi @MadelineKornack 

 

One way of doing this

 

Felipe_Ribeir0_0-1668464282137.png

 

binuacs
20 - Arcturus

@MadelineKornack One way of doing this with the DateTime tool

binuacs_0-1668465631092.png

 

grazitti_sapna
17 - Castor

@MadelineKornack , You can achieve this using formula tool. You just need to specify the current format of your date and then the required format in the outside function of DateTimeFormat as below: You can also use DateTime tool twice as mentioned by @binuacs  if you are comfortable with it. But I would recommend using 1 tool instead of 2 to decrease complexity in case of large workflows.

 

grazitti_sapna_0-1668485271310.png

 

Sapna Gupta
Labels