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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Leela
Contributor
Contributor

Converting Time stamp in Qlik Dashboard based on user local time

Hi 

I am trying to Convert my DB Time Stamp (Which is in 'UTC') to User local system time.

I used the function to convert and it is working fine in local copy but not in Qlik server. Qlik server timing is in 'ETC' and it is always converting  UTC to ETC but not based on the user local time.

=' USER SYSTEM TIME '&chr(10)&ConvertToLocalTime(Date(Max({1}DBdate),'MM/DD/YYYY hh:mm:ss TT'))

My DB date data Format : 3/10/2021 8:47:11 AM

Could someone help here would be appreciated...............

 

2 Replies
Or
MVP
MVP

What result are you getting for something simple such as ConvertToLocalTime(Now())? Do you get a correct value when you select a single DBdate and just use ConvertToLocalTime(DBdate)? Do you get the correct value when just using LocalTime()?

Note that the date() part of your formula appears to be unnecessary - if DBdate is a valid date, the format won't matter when you input it into ConvertToLocalTime(), so you can just use ConvertToLocalTime(Max({1}DBdate)). You can then format that with an exterior date() if you need to, but the interior date() shouldn't be necessary here.

 

Leela
Contributor
Contributor
Author

Thanks for the reply!

Yes, Iam getting my local time correctly.

Issue was when I deploy it in the Qlik server and open it through URL I am getting my DB date converting to  EST timing only but not my local time. I removed the date part also and tried still the same.

How can I convert the DB date into my local time?

Leela_0-1617720803862.png

Leela_1-1617720857222.png