Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
vlad_komarov
Partner - Specialist III
Partner - Specialist III

Time() or Timestamp() formatting for INTEGER value(s)

Dear all,

I am looking for simple way to display Timestamp data for Integer values.

Like 1 = 24:00:00, 2 = 48:00:00, etc

Using Time() or TimeStamp() does not help, it's always displaying 00:00:00 for the whole numbers.

I do not want to use IFs or similar approach, I was hoping it could be achieved much more elegant way...

Thanks,

Vlad

1 Solution

Accepted Solutions
ezkurdim
Contributor II
Contributor II

Replace Time with Interval !

View solution in original post

5 Replies
Thiago_Justen_

Hello Vladimir,

About your question, make sure your field is formatted as number. Try this out:

Time(Num#(YourField))

Cheers

Thiago Justen Teixeira Gonçalves
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago
vlad_komarov
Partner - Specialist III
Partner - Specialist III
Author

Thanks, Thiago,

But it did not help much:

Here is my code:

let vStep = 1;

set vTrace = 'The Requested Step value = ' & num($(vStep)) & ' or ' & Time(num#('$(vStep)'), 'hh:mm:ss')

The result:

The Requested Step value = 1 or 00:00:00

Vlad

ezkurdim
Contributor II
Contributor II

Replace Time with Interval !

dwforest
Specialist II
Specialist II

If you put in context your end goal it might help.

time values are < 1, so any whole number will have 0 time.

As shown in Help, 0.375 = 09:00

vlad_komarov
Partner - Specialist III
Partner - Specialist III
Author

Raymond,

How the !@#!@ I forgot about that function???

Thanks!!

Vlad