We've recently made an accessibility improvement to the community and therefore posts without any content are no longer allowed. Please use the spoiler feature or add a short message in the message body in order to submit your weekly challenge.

Weekly Challenge

Solve the challenge, share your solution and summit the ranks of our Community!

Also available in | Français | Português | Español | 日本語

We're actively looking for ideas on how to improve Weekly Challenges and would love to hear what you think!

Submit Feedback

Challenge #34: Date-Time Formatting

ACE Emeritus
ACE Emeritus

Great advice on creating macros - build the logic without the macro settings, then "convert" to macro in a new workflow.

Went with Python on this one - Pandas to_datetime() function is AWESOME for datetime conversions. 

from ayx import Alteryx
import pandas as pd

df = Alteryx.read('#1')
df['DateTime_out'] = pd.to_datetime(df['date_time'])



7 - Meteor

Maybe too simple but this works.

7 - Meteor



I was able to get the solution only with a single datetime tool. Why is there any need to have text to column tool for this challenge or whether there is any need to apply formula tool to get the output. Or whether I missed to understand the question correctly. Would be more than happy if some could correct me or make me realize the catch I'm missing out.


God bless you all. Thank you.

7 - Meteor

Not sure either but here is what i think.


I agreed that that's all there is to it (one formula tool is fine, or can complicate it with more tools), but maybe the key here is to learn about packaging the tools and creating one macro that you can just feed the input without much configuration by user (ie. coding the formulas) to get the answers. Also, maybe you can design the macro to check for/handle exceptions, such as AM/PM vs 24hr time format.

8 - Asteroid

Regex parse is such a powerful tool and regex101.com is great for developing the correct expression





8 - Asteroid

Here my solution

8 - Asteroid

Please find attached my proposed solution.  



6 - Meteoroid

Managed to solve this with a simple Formula and DateTime tool.

9 - Comet

Great exercise!

8 - Asteroid

My Solution-