Important Community update: The process for changing your account details was updated on June 25th. Learn how this impacts your Community experience and the actions we suggest you take to secure your account here.

Alteryx Designer Desktop Discussions

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

Need to convert 05/22/2023 14:16:14 into 05/22/2023 02:16:14 PM

RajatRehria
8 - Asteroid

Hi all how can i convert this date 05/22/2023 14:16:14 into 05/22/2023 02:16:14 PM  format using DateTimeParse formula?

3 REPLIES 3
binuacs
20 - Arcturus

@RajatRehria 

 

DateTimeFormat(DateTimeParse([Date],”%m/%d/%Y %H:%M:%S”),”%m/%d/%Y %I:%M %p”)

DataNath
17 - Castor

Hey @RajatRehria, you can do that with the following formula, using DateTimeFormat to achieve your desired format. Important to note that this will still need to be stored as a string due to the non-ISO standard:

 

DateTimeFormat(
DateTimeParse([Input],'%m/%d/%Y %H:%M:%S'),
'%m/%d/%Y %I:%M:%S %p')

 

 

RajatRehria
8 - Asteroid

many thanks to both of you @binuacs and @DataNath for the solutions.

Labels