Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Difficulty formatting Time

I retrieve data from an SQL database where time is stored as an integer. After loading the time into Qlikview, is there a means by which I can format it so as to display as HH:MM. I tried changing the number format in properties section, but since the time is stored as an integer initially in the database, it does not work. Would anyone be able to help me on this.

eg: Integer 759 should be displayed as 7:59 aftre loading in QlikView

4 Replies
maxgro
MVP
MVP

maybe

Time#(num(yoursqlfield, '0000'), 'hhmm')

MK_QSL
MVP
MVP

=Time(TIme#(Num('759','0000'),'hhmm'),'hh:mm')

or

=Time(TIme#(Num(YourFieldName,'0000'),'hhmm'),'hh:mm')

Not applicable
Author

I just copy pasted your 2nd line of code and it worked. I am glad. Thank You very much.

MK_QSL
MVP
MVP

Glad that my solution worked for you.

Better if you close the thread by selecting correct answer so that others having same issue can use it.