I have a field of values which is given to me as integers. The problem I have is that the data is actually time. I need a way to convert the integers to time format. The data looks similar to below:
700 |
1559 |
15 |
935 |
My desire is to convert the time (either by formula or some other tool) to time as shown below:
7:00 |
15:59 |
0:15 |
9:35 |
The time is 24 hour clock and the returned integer will never exceed 4 digits. I am using Alteryx 10.6.
Solved! Go to Solution.
Hi @RSchomer
Will the following work:
PadLeft( Left([fld],Length([fld])-2) + ":" + Right([fld],2) ,5,"0")
You will first need to use "Select" to change the type to a string type of sufficient length.
That works pretty good. However, the formula returns a string. How do I convert that string to time format, so that I can use the DateTimeAdd and DateTimeDiff formulas?
The DateTime tool should work under Parse.
It should be able to convert to HH:mm:ss which will work with DateTimeAdd() and Diff()
thanks,
Dan
That's the info I needed. Thanks to both of you.