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

Announcements
Now accepting applications for the Qlik Luminary and Partner Ambassador Programs: Apply by July 6!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Need help with time stamp conversion

I am fetching data from db and storing the data in qvd . in this i am getting values of a date time field as number such as

1426807749 but when i am trying to convert this into time stamp .i am not getting the desired result when i am trying as below

MakeDate(Year(start_time),Month(start_time),Day(start_time)) as Outage_StartTime,        

timestamp(start_time) as start_time,

Please suggest how can we convert this into timestamp .

Labels (1)
12 Replies
sunny_talwar
MVP
MVP

Try this:

If(Len(Trim(start_time)) > 0, ConvertToLocalTime(Timestamp(25569 + start_time/86400),'GMT-06:00'), Now())

MarcoWedel
MVP
MVP

=ConvertToLocalTime(Alt(yourtimestampvalue,Now()),'GMT-06:00')

MarcoWedel
MVP
MVP

yourtimestampvalue in above expression has to be 25569+yourtimestampvalue/86400 instead.

So the whole expression should read in your case:

=ConvertToLocalTime(Alt(25569+start_time/86400,Now()),'GMT-06:00')

one example:

QlikCommunity_Thread_169137_Pic1.JPG

hope this helps

regards

Marco