<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to display 2 different time (UTC and PST) in the dashboard table? in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615442#M50492</link>
    <description>&lt;P&gt;Splunk does not have means for converting times to a specified time zone.&amp;nbsp; Times are stored as UTC internally and displayed in the user's selected time zone.&lt;/P&gt;&lt;P&gt;You can add code to shift times by some interval to simulate different time zones:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| makeresults 
| eval latest=_time
| eval locallatest=strftime(latest,"%Y-%m-%d %H:%M:%S %Z")
| eval utclatest=strftime(relative_time(latest, "+5h"),"%Y-%m-%d %H:%M:%S %Z")
| eval pdtlatest=strftime(relative_time(latest, "-3h"),"%Y-%m-%d %H:%M:%S %Z")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This code produces&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;_time&lt;/TD&gt;&lt;TD&gt;latest&lt;/TD&gt;&lt;TD&gt;locallatest&lt;/TD&gt;&lt;TD&gt;pdtlatest&lt;/TD&gt;&lt;TD&gt;utclatest&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;2022-09-30 13:43:24&lt;/TD&gt;&lt;TD&gt;1664559804&lt;/TD&gt;&lt;TD&gt;2022-09-30 13:43:24 EDT&lt;/TD&gt;&lt;TD&gt;2022-09-30 10:43:24 EDT&lt;/TD&gt;&lt;TD&gt;2022-09-30 18:43:24 EDT&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;As you can see, despite the different hours Splunk still considers all of the times as being in the same zone. (I modified the time zone strings to fit the table.)&amp;nbsp; If you remove the time zones provided by Splunk (by removing " %Z" from the format strings) then you'll get something close to what you seek.&amp;nbsp; It will, however, be somewhat fragile.&amp;nbsp; Since the relationships among the times are fixed, they may not be correct near daylight saving time transitions.&amp;nbsp; They're also specific to users in a single time zone so someone in a different zone (or with a different selected time zone) won't see the correct times.&lt;/P&gt;</description>
    <pubDate>Fri, 30 Sep 2022 18:02:38 GMT</pubDate>
    <dc:creator>richgalloway</dc:creator>
    <dc:date>2022-09-30T18:02:38Z</dc:date>
    <item>
      <title>How to display 2 different time (UTC and PST) in the dashboard table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615434#M50491</link>
      <description>&lt;P&gt;[| makeresults&lt;BR /&gt;| addinfo&lt;BR /&gt;| eval earliest=relative_time(info_min_time,"@d+7h")&lt;BR /&gt;| eval latest=relative_time(info_min_time,"@d+31h")&lt;BR /&gt;| fields earliest latest]| fields file_name batch_count entry_addenda_count total_debit_amount total_credit_amount |dedup file_name | eval total_debit_amount=total_debit_amount/100, total_credit_amount=total_credit_amount/100 | table _time file_name batch_count entry_addenda_count total_debit_amount total_credit_amount&lt;/P&gt;
&lt;P&gt;I am using above query&lt;BR /&gt;But want to show 2 different time zone PST and UTC in the table. Right now the time shown is in UTC&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="new - 1.png" style="width: 999px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/21799i2C3BE71C5DA11179/image-size/large?v=v2&amp;amp;px=999" role="button" title="new - 1.png" alt="new - 1.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Sep 2022 17:06:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615434#M50491</guid>
      <dc:creator>kkanand</dc:creator>
      <dc:date>2022-09-30T17:06:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to display 2 different time (UTC and PST) in the dashboard table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615442#M50492</link>
      <description>&lt;P&gt;Splunk does not have means for converting times to a specified time zone.&amp;nbsp; Times are stored as UTC internally and displayed in the user's selected time zone.&lt;/P&gt;&lt;P&gt;You can add code to shift times by some interval to simulate different time zones:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| makeresults 
| eval latest=_time
| eval locallatest=strftime(latest,"%Y-%m-%d %H:%M:%S %Z")
| eval utclatest=strftime(relative_time(latest, "+5h"),"%Y-%m-%d %H:%M:%S %Z")
| eval pdtlatest=strftime(relative_time(latest, "-3h"),"%Y-%m-%d %H:%M:%S %Z")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This code produces&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;_time&lt;/TD&gt;&lt;TD&gt;latest&lt;/TD&gt;&lt;TD&gt;locallatest&lt;/TD&gt;&lt;TD&gt;pdtlatest&lt;/TD&gt;&lt;TD&gt;utclatest&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;2022-09-30 13:43:24&lt;/TD&gt;&lt;TD&gt;1664559804&lt;/TD&gt;&lt;TD&gt;2022-09-30 13:43:24 EDT&lt;/TD&gt;&lt;TD&gt;2022-09-30 10:43:24 EDT&lt;/TD&gt;&lt;TD&gt;2022-09-30 18:43:24 EDT&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;As you can see, despite the different hours Splunk still considers all of the times as being in the same zone. (I modified the time zone strings to fit the table.)&amp;nbsp; If you remove the time zones provided by Splunk (by removing " %Z" from the format strings) then you'll get something close to what you seek.&amp;nbsp; It will, however, be somewhat fragile.&amp;nbsp; Since the relationships among the times are fixed, they may not be correct near daylight saving time transitions.&amp;nbsp; They're also specific to users in a single time zone so someone in a different zone (or with a different selected time zone) won't see the correct times.&lt;/P&gt;</description>
      <pubDate>Fri, 30 Sep 2022 18:02:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615442#M50492</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2022-09-30T18:02:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to display 2 different time (UTC and PST) in the dashboard table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615468#M50498</link>
      <description>&lt;P&gt;It worked!!!!!!!!!!!&lt;/P&gt;&lt;P&gt;Thank you so much&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="kkanand_0-1664576876883.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/21805i0C9C753E229CA8E0/image-size/medium?v=v2&amp;amp;px=400" role="button" title="kkanand_0-1664576876883.png" alt="kkanand_0-1664576876883.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Sep 2022 22:28:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615468#M50498</guid>
      <dc:creator>kkanand</dc:creator>
      <dc:date>2022-09-30T22:28:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to display 2 different time (UTC and PST) in the dashboard table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615473#M50501</link>
      <description>&lt;P&gt;It almost works.&amp;nbsp; The "PDT_Time_Zone" column has values that say "UTC", which I would find confusing as a user.&amp;nbsp; Take " %Z" out of the &lt;FONT face="courier new,courier"&gt;strftime&lt;/FONT&gt; functions to fix that.&lt;/P&gt;</description>
      <pubDate>Sat, 01 Oct 2022 00:39:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615473#M50501</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2022-10-01T00:39:48Z</dc:date>
    </item>
    <item>
      <title>Re: How to display 2 different time (UTC and PST) in the dashboard table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615481#M50505</link>
      <description>&lt;P&gt;I just noticed that my search is not giving out right results&lt;BR /&gt;&lt;BR /&gt;Time range is selected : 09/26 to 9/29&lt;/P&gt;&lt;P&gt;&amp;nbsp;But its showing results for&amp;nbsp;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;(9/26/22 7:00:00.000 AM to 9/27/22 7:00:00.000 AM)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="capt 2.png" style="width: 999px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/21808i5CB726FA8F52BFE0/image-size/large?v=v2&amp;amp;px=999" role="button" title="capt 2.png" alt="capt 2.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 01 Oct 2022 03:58:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615481#M50505</guid>
      <dc:creator>kkanand</dc:creator>
      <dc:date>2022-10-01T03:58:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to display 2 different time (UTC and PST) in the dashboard table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615494#M50506</link>
      <description>&lt;P&gt;The earliest and latest fields in the query override the time picker.&lt;/P&gt;</description>
      <pubDate>Sat, 01 Oct 2022 12:28:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-display-2-different-time-UTC-and-PST-in-the-dashboard/m-p/615494#M50506</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2022-10-01T12:28:29Z</dc:date>
    </item>
  </channel>
</rss>

