Community Halloween is live until October 31st! Complete any 2 quick activities to earn the 2025 Community Halloween badge. Feeling brave? Check out the activities here
Start Free Trial

Alteryx Designer Desktop Discussions

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

Parsing date and time into separate fields

SDCI
7 - Meteor

Hello.

 

I need break apart Activity Date/Time into discrete dates and times.  

 

For example I need the following activity date/time:  2016-10-24 06:00:24 broken out into 2 separate fields.

 

Date: 2016-10-24

Time: 06:00:24

 

 

 

2 REPLIES 2
michael_treadwell
ACE Emeritus
ACE Emeritus

Couple of different options here. I would say the easiest, if you format your DateTime field as a string would be to simply use Text To Columns and split on ' '. The other option, if you are less sure of the incoming format, would be to use the RegEx tool. See attached.

Joe_Mako
12 - Quasar

Another option is to use a Formula tool, setting the data type for two new fields to Date and Time respectively, both with the same expression.

 

For example:

 

Date Time.png

Labels
Top Solution Authors