Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
pgalvezt
Specialist
Specialist

Transform to Time

Hi! Please I need your help, I would like to transform my formula to time hh:mm:ss. I've tried with time, Interval and TimeStamp, but its not working. I´ve attached my qv file.

Thanks!

1 Solution

Accepted Solutions
CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     Try with this using mod function

     Time#(Floor(SumOfSum_DiferenciaCL/60) & ':'& Mod(SumOfSum_DiferenciaCL,60),'h:m')

Celambarasan

View solution in original post

11 Replies
Anonymous
Not applicable

Hi,

what is the field name that you are trying to convert?

pgalvezt
Specialist
Specialist
Author

Hi,

The Expression is (SumOfSum_DiferenciaCL/60) & ':'& ((SumOfSum_DiferenciaCL/60) - (SumOfSum_DiferenciaCL/60)*60). And this I need to pass To Time. For example: Sumof sum 18 that number I have to convert to time. In my Excel file I have: =INT(C2/60)&":"&INT(((C2/60)-INT(C2/60))*60),

so the number 18 is converted to 0:18.

CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     Did you tried with Time#?

     Time#(SumOfSum_DiferenciaCL/60) & ':'& ((SumOfSum_DiferenciaCL/60) - (SumOfSum_DiferenciaCL/60)*60,'h:m')

Hope it helps

Celambarasan

pgalvezt
Specialist
Specialist
Author

Hi, thanks for your reply but Still is not working

Time#(SumOfSum_DiferenciaCL/60,'h:m') & ':'& ((SumOfSum_DiferenciaCL/60) - (SumOfSum_DiferenciaCL/60)*60).

CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

    Paranthesis problem in previous post check the below expression.

     Time#((SumOfSum_DiferenciaCL/60) & ':'& ((SumOfSum_DiferenciaCL/60) - (SumOfSum_DiferenciaCL/60)*60),'h:m')

Celambarasan

pgalvezt
Specialist
Specialist
Author

Hi, Still not working. I´ve tried with format number but nothing happened.

pgalvezt
Specialist
Specialist
Author

Any help?

Thanks!

CELAMBARASAN
Partner - Champion
Partner - Champion

Hi

     I think it returns decimal values.

     Check with this

      Time#(Floor(SumOfSum_DiferenciaCL/60) & ':'& Floor((SumOfSum_DiferenciaCL/60) - (SumOfSum_DiferenciaCL/60)*60),'h:m')

Hope it helps

Celambarasan

pgalvezt
Specialist
Specialist
Author

Thank you for your reply. Almost ready. but I think is not working yet. The idea is emule the excel file. I´ve attached the excel file for better comprehenssion.

Thanks