Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

time format

hi,

i have two kind of time formats:

00:01:10 wich is hh:mm:ss and 01:10 wich is mm:ss.

i need to convert the second format to hh:mm:ss

how can i do this?

i've tried with timestamp# (date,'hh:mm:ss') and whit Date#(date,'hh:mm:ss) but it didn't do what i need.

time.jpg

thanks for your help!

1 Solution

Accepted Solutions
Jason_Michaelides
Partner - Master II
Partner - Master II

try:

Time(Time#(Duration,'mm:ss'),'hh:mm:ss')

Hope this helps,

Jason

View solution in original post

3 Replies
swuehl
MVP
MVP

Try using the alt() function in combination with interval# / interval functions:

LOAD

...

interval(alt(interval#(Duration,'hh:mm:ss'),interval#(Duration,'mm:ss')),'hh:mm:ss') as NewField,

...

FROM ...

Jason_Michaelides
Partner - Master II
Partner - Master II

try:

Time(Time#(Duration,'mm:ss'),'hh:mm:ss')

Hope this helps,

Jason

Not applicable
Author

thanks for your answer it really helped me.