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']) Alteryx.write(df,3)
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.
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.