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

Announcements
Note: You may notice some temporary visual or styling issues in the Community. Our vendor is actively investigating.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Converting Seconds to hh:mm - problem

Hi , I have a '[Difference Seconds]' field that totals to :125040

If I use the following expression to try and convert this to hh:mm:ss :

=sum(Time(Time#([Difference Seconds],'ss'),'hh:mm:ss'))

the output is 10:44:00.  The actual hh:mm that should be displayed is around 34 hours.  Can anyone help to get the correct output?

Thanks,

Tom

3 Replies
swuehl
MVP
MVP

Use interval() and interval#() instead of Time() / Time#().

=Interval#(sum([Difference Seconds]),'ss'),'hh:mm:ss')

MK_QSL
MVP
MVP

=Interval(125040/(3600*24),'hh:mm:ss')

alexandros17
Partner - Champion III
Partner - Champion III

=Text(Div(125040,3600)) & ':' & Text(Div(125040 - Div(125040,3600) * 3600 , 60))