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.

Change Date Format in Alteryx

ebowlan
6 - Meteoroid

I have data from a database that shows the date format as MM-DD-YYYY HH:SS.  I am not able to change this in the operating system.  Is there a way to setup a formula in Alteryx to change the date format to be DD-MM-YYYY HH:SS?  Sample date file attached.  

2 REPLIES 2
atcodedog05
22 - Nova
22 - Nova

Hi @ebowlan 

 

Strangely i am getting below date format from your excel file

atcodedog05_0-1648231030369.png

 

Here is how you can do it. Multi-field formula tool is really helpful when you want to apply formula on multiple columns. Refer below interactive lesson to learn more about its usage.

https://community.alteryx.com/t5/Interactive-Lessons/Multi-Field-Formulas/ta-p/424422

 

You can use DateTimePrase() function to convert non Alteryx date format to Alteryx date format (YYYY-MM-DD HH:MM:SS). Then use DateTimeFormat() to convert it into the required format. Refer the below page to understand more on its usage.

https://help.alteryx.com/designer-cloud/datetime-functions#:~:text=Alteryx%20uses%20the%20ISO%20form....

 

Workflow for your usecase would be like below

atcodedog05_0-1648231686516.png

 

Hope this helps : )

DavidP
17 - Castor
17 - Castor

Hi @ebowlan 

 

You can use a datetimeparse function to convert the value to a standard Alteryx datetime format, which is YYYY-MM-DD HH:MM:SS and then use a datetimefromat function to convert it to your desired format.

 

DateTimeParse([Date],'%m/%d/%Y %H:%M')

DateTimeFormat([newdate],'%d/%m/%Y %H:%M')

 

DavidP_0-1648231544596.png

 

Labels