In case you missed the announcement: Alteryx One is here, and so is the Spring Release! Learn more about these new and exciting releases here!

Alteryx Designer Desktop Discussions

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

Date format

tww
8 - Asteroid

Hi all,

 

How could I format/extract the following value so I can get 2 separate values for the weekday and date.

 

Wed Aug 31 23:30:17 CDT 2022

 

Output

 

Wed08/31/2022

 

Thank you

4 REPLIES 4
Yoshiro_Fujimori
15 - Aurora
15 - Aurora

@tww ,

DateTime functions can handle date and time very frexibly.

https://help.alteryx.com/20223/designer/datetime-functions

 

Used formula

Date = DateTimeParse([Data],"%a %b %d %H:%M:%S CDT %Y")

DayOf Week = DateTimeFormat([Date],"%a")

Date2 = DateTimeFormat([Date],"%m/%d/%Y")

 

Workflow

Yoshiro_Fujimori_0-1680130685608.png

Output

Yoshiro_Fujimori_1-1680130699235.png

 

Good luck!

martinding
13 - Pulsar

Hi @tww , 

 

You can try the following approach:

1. Parse the string to datetime format

2. Format the datetime into the parts you want (e.g. day of week, year, date)

 

martinding_0-1680130952542.png

 

tww
8 - Asteroid

Thank you, @Yoshiro_Fujimori 

tww
8 - Asteroid

Thank you, @martinding 

Labels
Top Solution Authors