Dashboards & Visualizations

How to display last update time for a specific timezone irrespective of the local timezone?

Taruchit
Contributor

Hi All,

I referred the following https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-the-page-last-updated-time-... to display the last refreshed/updated date-time on the dashboard.

In my case, it uses my local system's timezone to display the result. I changed the timezone in Splunk from default to EST, but it still takes and displays time as per local timezone. Can anybody please share a way to display the date time for a specific timezone irrespective of the local timezone on which the dashboard is being accessed? 

Thank you

Labels (2)
Tags (1)
0 Karma
1 Solution

PickleRick
SplunkTrust
SplunkTrust

Short answer is - you can't.

Long answer is - splunk strftime always shows time in the timezone of your user. And there's a pretty solid rationale for that - you don't want your users get confused because someone hardcoded some static timezone information in the report/dashboard/whatever. You can "cheat" a bit by calculating an offset between different timezones and then render the timestamp in the user's timezone , then cut the timezone information and glue some static timezone string - a very, very ugly solution and I would advise wholeheartedly against it.

View solution in original post

0 Karma

PickleRick
SplunkTrust
SplunkTrust

Short answer is - you can't.

Long answer is - splunk strftime always shows time in the timezone of your user. And there's a pretty solid rationale for that - you don't want your users get confused because someone hardcoded some static timezone information in the report/dashboard/whatever. You can "cheat" a bit by calculating an offset between different timezones and then render the timestamp in the user's timezone , then cut the timezone information and glue some static timezone string - a very, very ugly solution and I would advise wholeheartedly against it.

0 Karma

Taruchit
Contributor

Thank you for sharing your inputs.

0 Karma
Get Updates on the Splunk Community!

Modern way of developing distributed application using OTel

Recently, I had the opportunity to work on a complex microservice using Spring boot and Quarkus to develop a ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had 3 releases of new security content via the Enterprise Security ...

Archived Metrics Now Available for APAC and EMEA realms

We’re excited to announce the launch of Archived Metrics in Splunk Infrastructure Monitoring for our customers ...