Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I have a variable T representing a time. This variable is store in the original data as numeric like this :
829, 1200, 1659, 2355
829 means 8H 29 minutes
1200 means noon
I'd like to transform my variable in a new one which I could use as really time variable (hh:mm) to do some laps calculation.
Thanks in advance for any help
JJ
This will work:
=
time(time#(num(YourTimeField, '0000'), 'hhmm'))
The part num(YourTimeField, '0000') make all values 4-digits long. The time#() "explains" the format. Function time() converts to "noraml" format.
This will work:
=
time(time#(num(YourTimeField, '0000'), 'hhmm'))
The part num(YourTimeField, '0000') make all values 4-digits long. The time#() "explains" the format. Function time() converts to "noraml" format.
You could divide your time in seconds by 86400 (total number of seconds in one day) then display as time/timestamp format in the "number" tab
Hi Michael,
I have the same issue, My times are displayed as numbers, but mine include seconds, so they are a maximum of 6 numbers long. I assume i just add two extro zeros in the example you gave.
i.e.
=
time(time#(num(TransStartTime, '000000'), 'hhmmss')) ,
But how would i write this into my script?
Chris
Chris,
This looks correct to me. If it is in the load script, it would be
LOAD
...
time(time#(num(TransStartTime, '000000'), 'hhmmss')) as Time,
...
RESIDENT ...
(Dont'd try it in SQL SELECT)