<?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 convert epoch time to a desired time zone? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623820#M216878</link>
    <description>&lt;P&gt;hi small query&lt;/P&gt;&lt;P&gt;i have created lookup file and lookup definition&lt;/P&gt;&lt;P&gt;while creating automatic lookup what should i keep for&amp;nbsp;Lookup input fields and&amp;nbsp;Lookup output field&lt;/P&gt;&lt;P&gt;below is the query i was using and getting error&lt;/P&gt;&lt;P&gt;sourcetype=autosys_POC&lt;BR /&gt;| lookup timezone TIMEZONE output offset&lt;BR /&gt;| foreach LAST_* NEXT_*&lt;BR /&gt;| fieldformat STARTTIME = strftime(LAST_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/P&gt;</description>
    <pubDate>Fri, 09 Dec 2022 09:38:53 GMT</pubDate>
    <dc:creator>sekhar463</dc:creator>
    <dc:date>2022-12-09T09:38:53Z</dc:date>
    <item>
      <title>How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623611#M216780</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hi&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;from below events how to convert&amp;nbsp;epoch time to a desired time zone&lt;/P&gt;&lt;P&gt;want to convert&amp;nbsp;LAST_START="1670326641", LAST_END="1670326670", NEXT_START="1670412600", into desired time zone based on TIMEZONE field&lt;/P&gt;</description>
      <pubDate>Thu, 19 Oct 2023 12:59:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623611#M216780</guid>
      <dc:creator>sekhar463</dc:creator>
      <dc:date>2023-10-19T12:59:55Z</dc:date>
    </item>
    <item>
      <title>Re: how to convert epoch time to a desired time zone</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623626#M216785</link>
      <description>&lt;P&gt;You will need a lookup table to interpret TIMEZONE &amp;nbsp;as&amp;nbsp;SPL does not provide such meta data., e.g.,&lt;/P&gt;&lt;TABLE border="1" width="46.69211195928753%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="23.02798982188295%"&gt;TIMEZONE&lt;/TD&gt;&lt;TD width="23.664122137404576%"&gt;offset&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="23.02798982188295%"&gt;ZULU&lt;/TD&gt;&lt;TD width="23.664122137404576%"&gt;0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="23.02798982188295%"&gt;CENTRAL&lt;/TD&gt;&lt;TD width="23.664122137404576%"&gt;-6&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="23.02798982188295%"&gt;PACIFIC&lt;/TD&gt;&lt;TD width="23.664122137404576%"&gt;-8&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;(I know the wording is extremely US-centric - but that's how your data look like.) Let's call this table timezone. &amp;nbsp;Then, you just perform a lookup and calculate.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| lookup timezone TIMEZONE output offset
| foreach LAST_* NEXT_*
  [ fieldformat &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; = strftime(&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")") ]&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 07 Dec 2022 18:00:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623626#M216785</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-12-07T18:00:43Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623676#M216810</link>
      <description>&lt;P&gt;hai i didnt understand this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;can you tell me clearly&lt;/P&gt;</description>
      <pubDate>Thu, 08 Dec 2022 07:59:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623676#M216810</guid>
      <dc:creator>sekhar463</dc:creator>
      <dc:date>2022-12-08T07:59:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623678#M216811</link>
      <description>&lt;P&gt;hi can you give me complete query as an example after lookup file creation&lt;/P&gt;</description>
      <pubDate>Thu, 08 Dec 2022 08:09:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623678#M216811</guid>
      <dc:creator>sekhar463</dc:creator>
      <dc:date>2022-12-08T08:09:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623780#M216854</link>
      <description>&lt;P&gt;You can follow this document to set up a lookup:&amp;nbsp;&lt;A href="https://docs.splunk.com/Documentation/Splunk/latest/Knowledge/DefineanautomaticlookupinSplunkWeb#collapseDesktop10" target="_blank" rel="noopener"&gt;Use lookups in Splunk Web&lt;/A&gt;; per&amp;nbsp;&lt;A href="https://docs.splunk.com/Documentation/Splunk/latest/Knowledge/Usefieldlookupstoaddinformationtoyourevents#Define_a_CSV_lookup_in_Splunk_Web" target="_blank" rel="noopener"&gt;Define a CSV lookup in Splunk Web&lt;/A&gt;:&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;SPAN&gt;CSV lookups are best for small sets of data. The general workflow for creating a CSV lookup in Splunk Web is to upload a file, share the lookup table file, and then create the lookup definition from the lookup table file. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Hope this helps.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Dec 2022 01:26:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623780#M216854</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-12-09T01:26:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623820#M216878</link>
      <description>&lt;P&gt;hi small query&lt;/P&gt;&lt;P&gt;i have created lookup file and lookup definition&lt;/P&gt;&lt;P&gt;while creating automatic lookup what should i keep for&amp;nbsp;Lookup input fields and&amp;nbsp;Lookup output field&lt;/P&gt;&lt;P&gt;below is the query i was using and getting error&lt;/P&gt;&lt;P&gt;sourcetype=autosys_POC&lt;BR /&gt;| lookup timezone TIMEZONE output offset&lt;BR /&gt;| foreach LAST_* NEXT_*&lt;BR /&gt;| fieldformat STARTTIME = strftime(LAST_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/P&gt;</description>
      <pubDate>Fri, 09 Dec 2022 09:38:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623820#M216878</guid>
      <dc:creator>sekhar463</dc:creator>
      <dc:date>2022-12-09T09:38:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623824#M216879</link>
      <description>&lt;P&gt;foreach opens a subsearch; you need square brackets around it.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| lookup timezone TIMEZONE output offset
| foreach LAST_* NEXT_*
  [ fieldformat &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; = strftime(&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")") ]&lt;/LI-CODE&gt;&lt;P&gt;You can then rename those fields as you like. &amp;nbsp;If you don't want to use foreach loop, you can spell them out individually, i.e.,&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| lookup timezone TIMEZONE output offset
| fieldformat STARTTIME = strftime(LAST_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")
| fieldformat ENDTIME = strftime(LAST_END + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")
| fieldformat NEXTTIME = strftime(NEXT_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Dec 2022 10:28:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623824#M216879</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-12-09T10:28:51Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623833#M216886</link>
      <description>&lt;P&gt;Hai tried but getting error while using the search below.&lt;/P&gt;&lt;P&gt;i guess automatic lookup is incorrect, can you tell me the input and output fields for automatic lookup&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;sourcetype=autosys_POC&lt;BR /&gt;| lookup Timezone TIMEZONE output offset&lt;BR /&gt;| fieldformat STARTTIME = strftime(LAST_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat ENDTIME = strftime(LAST_END + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat NEXTTIME = strftime(NEXT_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;Error in 'lookup' command: Could not construct lookup 'Timezone, TIMEZONE, output, offset'. See search.log&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;The lookup table 'Timezone' does not exist or is not available.&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;The search job has failed due to an error. You may be able view the job in the&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sekhar463_0-1670590015776.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/22944i97147161A44B55FB/image-size/medium?v=v2&amp;amp;px=400" role="button" title="sekhar463_0-1670590015776.png" alt="sekhar463_0-1670590015776.png" /&gt;&lt;/span&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 09 Dec 2022 12:47:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623833#M216886</guid>
      <dc:creator>sekhar463</dc:creator>
      <dc:date>2022-12-09T12:47:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623874#M216897</link>
      <description>&lt;P&gt;The sceenshot suggests that you named the lookup "&lt;EM&gt;timezonelookupdefine&lt;/EM&gt;", not "&lt;U&gt;Timezone&lt;/U&gt;". If so,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;sourcetype=autosys_POC
| lookup timezonelookupdefine TIMEZONE output offset
| fieldformat STARTTIME = strftime(LAST_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")
| fieldformat ENDTIME = strftime(LAST_END + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")
| fieldformat NEXTTIME = strftime(NEXT_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;From&amp;nbsp;&lt;A href="https://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Lookup#Syntax" target="_blank" rel="noopener"&gt;lookup#Syntax&lt;/A&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;H2&gt;&lt;SPAN class=""&gt;Syntax&lt;/SPAN&gt;&lt;/H2&gt;&lt;P&gt;The required syntax is in &lt;STRONG&gt;bold&lt;/STRONG&gt;.&lt;/P&gt;&lt;STRONG&gt;lookup&lt;/STRONG&gt; [local=&amp;lt;bool&amp;gt;] [update=&amp;lt;bool&amp;gt;] &lt;STRONG&gt;&amp;lt;lookup-table-name&amp;gt;&lt;/STRONG&gt; ( &amp;lt;lookup-field&amp;gt; [AS &amp;lt;event-field&amp;gt;] )... [ OUTPUT | OUTPUTNEW (&amp;lt;lookup-destfield&amp;gt; [AS &amp;lt;event-destfield&amp;gt;] )... ]&lt;/BLOCKQUOTE&gt;</description>
      <pubDate>Fri, 09 Dec 2022 20:03:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623874#M216897</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-12-09T20:03:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623887#M216900</link>
      <description>&lt;P&gt;Side note: You do not need to set up automatic lookup for this task unless there is a genuine need to.&lt;/P&gt;</description>
      <pubDate>Sat, 10 Dec 2022 05:16:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623887#M216900</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-12-10T05:16:43Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623969#M216934</link>
      <description>&lt;P&gt;Hai, i have updated the search but not getting new filelds created.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;index=ivz_onboarding_css_autosys source=Autosyscss1&lt;BR /&gt;| lookup timezonelookupdefine TIMEZONE output offset&lt;BR /&gt;| fieldformat STARTTIME = strftime(LAST_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat ENDTIME = strftime(LAST_END + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat NEXTTIME = strftime(NEXT_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;resulted event :&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;2022-12-12&lt;/SPAN&gt; &lt;SPAN class=""&gt;03:26:06.881&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN class=""&gt;JOID=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;119829&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;JOB_NAME=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;PNC-PMT-UI-DATA-CACHE-REFRESH-GMAG-FUNDS&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;JOB_GROUP=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;PMT&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;TIMEZONE=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;EST5EDT&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;RUN_NUM=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;403234100&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;NTRY=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;RUN_MACHINE=&lt;/SPAN&gt;&lt;SPAN&gt;" ", &lt;/SPAN&gt;&lt;SPAN class=""&gt;STATUS_CODE=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;9&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;STATUS=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;ACTIVATED&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;LAST_START=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;LAST_END=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;1670579164&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;NEXT_START=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;1670585400&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;DATE_CONDITIONS=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;DAYS_OF_WEEK=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;mo&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt;tu&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt;we&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt;th&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt;fr&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;EXCLUDE_CALENDAR=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;EST-NYSE-HOLIDAYS&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;RUNTIME=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;1670579164&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;EXIT_CODE=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;-&lt;SPAN class=""&gt;656"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 12 Dec 2022 09:32:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/623969#M216934</guid>
      <dc:creator>sekhar463</dc:creator>
      <dc:date>2022-12-12T09:32:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/624084#M216960</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;SPAN class=""&gt;2022-12-12&lt;/SPAN&gt; &lt;SPAN class=""&gt;03:26:06.881&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN class=""&gt;JOID=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;119829&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;JOB_NAME=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;PNC-PMT-UI-DATA-CACHE-REFRESH-GMAG-FUNDS&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;JOB_GROUP=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;PMT&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;TIMEZONE=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;EST5EDT&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;RUN_NUM=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;403234100&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;NTRY=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;RUN_MACHINE=&lt;/SPAN&gt;&lt;SPAN&gt;" ", &lt;/SPAN&gt;&lt;SPAN class=""&gt;STATUS_CODE=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;9&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;STATUS=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;ACTIVATED&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;LAST_START=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;LAST_END=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;1670579164&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;NEXT_START=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;1670585400&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;DATE_CONDITIONS=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;DAYS_OF_WEEK=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;mo&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt;tu&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt;we&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt;th&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt;fr&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;EXCLUDE_CALENDAR=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;EST-NYSE-HOLIDAYS&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;RUNTIME=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;1670579164&lt;/SPAN&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN class=""&gt;EXIT_CODE=&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;-&lt;SPAN class=""&gt;656"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Here, the event's TIMEZONE is EST5EDT. &amp;nbsp;Does your timezonelookupdefine contain this timezone? A simple way to test is&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| makeresults
| eval TIMEZONE = "EST5EDT"
| lookup timezonelookupdefine TIMEZONE output offset&lt;/LI-CODE&gt;&lt;P&gt;A side note about EST5EDT: You realize that this poses an additional challenge in that offset is 5 in the winter and 4 in the summer, right? (At least before the new law takes effect next year.)&lt;/P&gt;</description>
      <pubDate>Tue, 13 Dec 2022 04:46:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/624084#M216960</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-12-13T04:46:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/624102#M216965</link>
      <description>&lt;P&gt;hi i have added timezone for EST in lookup and doing search but its not creating new fields&lt;/P&gt;&lt;P&gt;STARTTIME,ENDTIME ,NEXTTIME&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;index=ivz_onboarding_css_autosys source=Autosyscss1&lt;BR /&gt;| eval NEW_START_TIME=strftime(LAST_START,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| eval NEW_END_TIME=strftime(LAST_END,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| eval NEW_NEXT_TIME=strftime(NEXT_START,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| lookup timezonelookupdefine TIMEZONE output offset&lt;BR /&gt;| fieldformat STARTTIME = strftime(NEW_START_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat ENDTIME = strftime(NEW_END_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat NEXTTIME = strftime(NEW_NEXT_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/P&gt;</description>
      <pubDate>Tue, 13 Dec 2022 08:48:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/624102#M216965</guid>
      <dc:creator>sekhar463</dc:creator>
      <dc:date>2022-12-13T08:48:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/624108#M216968</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;index=ivz_onboarding_css_autosys source=Autosyscss1&lt;BR /&gt;| eval NEW_START_TIME=strftime(LAST_START,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| eval NEW_END_TIME=strftime(LAST_END,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| eval NEW_NEXT_TIME=strftime(NEXT_START,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| lookup timezonelookupdefine TIMEZONE output offset&lt;BR /&gt;| fieldformat STARTTIME = strftime(NEW_START_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat ENDTIME = strftime(NEW_END_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat NEXTTIME = strftime(NEW_NEXT_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/BLOCKQUOTE&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Of course you wouldn't have new fields. &amp;nbsp;You are trying to apply strftime on string fields NEW_START_TIME, etc. &amp;nbsp;If you have copied my sample, it would have given you results.&lt;/P&gt;&lt;P&gt;To illustrate, I have made a sample lookup "&lt;SPAN&gt;timezonelookupdefine"&lt;/SPAN&gt; with these four:&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;TIMEZONE&lt;/TD&gt;&lt;TD&gt;offset&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;ZULU&lt;/TD&gt;&lt;TD&gt;0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;EST5EDT&lt;/TD&gt;&lt;TD&gt;-5&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;CENTRAL&lt;/TD&gt;&lt;TD&gt;-6&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;PACIFIC&lt;/TD&gt;&lt;TD&gt;-8&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screen Shot 2022-12-13 at 1.25.08 AM.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/22983iFF1AEC245129BFEC/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Screen Shot 2022-12-13 at 1.25.08 AM.png" alt="Screen Shot 2022-12-13 at 1.25.08 AM.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;(I'm using a simple offset for EST5EDT here. &amp;nbsp;Handling daylight savings time will drain your brain, as it has drained many a developers'.) &amp;nbsp;Then, I run the following against your sample data:&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;| lookup timezonelookupdefine TIMEZONE output offset
| fieldformat STARTTIME = strftime(LAST_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")
| fieldformat ENDTIME = strftime(LAST_END + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")
| fieldformat NEXTTIME = strftime(NEXT_START + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")
``` replace fieldformmat with eval if you want to use these as fields ```&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Note: No strftime before lookup! &amp;nbsp;This is the output&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="153.953125px" height="25px"&gt;DATE_CONDITIONS&lt;/TD&gt;&lt;TD width="132.03125px" height="25px"&gt;DAYS_OF_WEEK&lt;/TD&gt;&lt;TD width="170.984375px" height="25px"&gt;EXCLUDE_CALENDAR&lt;/TD&gt;&lt;TD width="95.65625px" height="25px"&gt;EXIT_CODE&lt;/TD&gt;&lt;TD width="104.1875px" height="25px"&gt;JOB_GROUP&lt;/TD&gt;&lt;TD width="94.546875px" height="25px"&gt;JOB_NAME&lt;/TD&gt;&lt;TD width="68.609375px" height="25px"&gt;JOID&lt;/TD&gt;&lt;TD width="107px" height="25px"&gt;LAST_END&lt;/TD&gt;&lt;TD width="105.78125px" height="25px"&gt;LAST_START&lt;/TD&gt;&lt;TD width="107.390625px" height="25px"&gt;NEXT_START&lt;/TD&gt;&lt;TD width="50.9375px" height="25px"&gt;NTRY&lt;/TD&gt;&lt;TD width="107px" height="25px"&gt;RUNTIME&lt;/TD&gt;&lt;TD width="122.546875px" height="25px"&gt;RUN_MACHINE&lt;/TD&gt;&lt;TD width="97.40625px" height="25px"&gt;RUN_NUM&lt;/TD&gt;&lt;TD width="93.140625px" height="25px"&gt;STATUS&lt;/TD&gt;&lt;TD width="40px" height="25px"&gt;STATUS_CODE&lt;/TD&gt;&lt;TD width="78.078125px" height="25px"&gt;TIMEZONE&lt;/TD&gt;&lt;TD width="40px" height="25px"&gt;offset&lt;/TD&gt;&lt;TD width="88.640625px" height="25px"&gt;ENDTIME&lt;/TD&gt;&lt;TD width="88.640625px" height="25px"&gt;NEXTTIME&lt;/TD&gt;&lt;TD width="88.640625px" height="25px"&gt;STARTTIME&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="153.953125px" height="135px"&gt;1&lt;/TD&gt;&lt;TD width="132.03125px" height="135px"&gt;mo,tu,we,th,fr&lt;/TD&gt;&lt;TD width="170.984375px" height="135px"&gt;EST-NYSE-HOLIDAYS&lt;/TD&gt;&lt;TD width="95.65625px" height="135px"&gt;-656&lt;/TD&gt;&lt;TD width="104.1875px" height="135px"&gt;PMT&lt;/TD&gt;&lt;TD width="94.546875px" height="135px"&gt;PNC-PMT-UI-DATA-CACHE-REFRESH-GMAG-FUNDS&lt;/TD&gt;&lt;TD width="68.609375px" height="135px"&gt;119829&lt;/TD&gt;&lt;TD width="107px" height="135px"&gt;1670579164&lt;/TD&gt;&lt;TD width="105.78125px" height="135px"&gt;0&lt;/TD&gt;&lt;TD width="107.390625px" height="135px"&gt;1670585400&lt;/TD&gt;&lt;TD width="50.9375px" height="135px"&gt;0&lt;/TD&gt;&lt;TD width="107px" height="135px"&gt;1670579164&lt;/TD&gt;&lt;TD width="122.546875px" height="135px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="97.40625px" height="135px"&gt;403234100&lt;/TD&gt;&lt;TD width="93.140625px" height="135px"&gt;ACTIVATED&lt;/TD&gt;&lt;TD width="40px" height="135px"&gt;9&lt;/TD&gt;&lt;TD width="78.078125px" height="135px"&gt;EST5EDT&lt;/TD&gt;&lt;TD width="40px" height="135px"&gt;-5&lt;/TD&gt;&lt;TD width="88.640625px" height="135px"&gt;2022-12-09 01:45:59 (EST5EDT)&lt;/TD&gt;&lt;TD width="88.640625px" height="135px"&gt;2022-12-09 03:29:55 (EST5EDT)&lt;/TD&gt;&lt;TD width="88.640625px" height="135px"&gt;1969-12-31 15:59:55 (EST5EDT)&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screen Shot 2022-12-13 at 1.47.59 AM.png" style="width: 999px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/22984i53F889F9429A10E0/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screen Shot 2022-12-13 at 1.47.59 AM.png" alt="Screen Shot 2022-12-13 at 1.47.59 AM.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;(If you want to use the display values as field for future calculation, use eval instead of fieldformat.)&lt;/P&gt;&lt;P&gt;As shown in the above screenshot, I emulated your last illustrated input using&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| makeresults
| fields - _time
| eval _raw = "2022-12-12 03:26:06.881, JOID=\"119829\", JOB_NAME=\"PNC-PMT-UI-DATA-CACHE-REFRESH-GMAG-FUNDS\", JOB_GROUP=\"PMT\", TIMEZONE=\"EST5EDT\", RUN_NUM=\"403234100\", NTRY=\"0\", RUN_MACHINE=\" \", STATUS_CODE=\"9\", STATUS=\"ACTIVATED\", LAST_START=\"0\", LAST_END=\"1670579164\", NEXT_START=\"1670585400\", DATE_CONDITIONS=\"1\", DAYS_OF_WEEK=\"mo,tu,we,th,fr\", EXCLUDE_CALENDAR=\"EST-NYSE-HOLIDAYS\", RUNTIME=\"1670579164\", EXIT_CODE=\"-656\""
| extract
| fields - _raw
``` data emulation above ```&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;All of these you can test for yourself. &amp;nbsp;Except you still need to make sure that the lookup table contains the correct timezone strings and offset values, and the lookup is spelled correctly.&lt;/P&gt;</description>
      <pubDate>Tue, 13 Dec 2022 10:01:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/624108#M216968</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2022-12-13T10:01:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert epoch time to a desired time zone?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/624122#M216976</link>
      <description>&lt;P&gt;hai Thanks&amp;nbsp;&lt;/P&gt;&lt;P&gt;i have confused, i am using the query but not getting fields added.&lt;/P&gt;&lt;P&gt;could you give complete&amp;nbsp; search&amp;nbsp;&lt;/P&gt;&lt;P&gt;index=ivz_onboarding_css_autosys source=Autosyscss1&lt;BR /&gt;| eval NEW_START_TIME=strftime(LAST_START,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| eval NEW_END_TIME=strftime(LAST_END,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| eval NEW_NEXT_TIME=strftime(NEXT_START,"%Y/%m/%d %H:%M:%S")&lt;BR /&gt;| lookup timezonelookupdefine TIMEZONE output offset&lt;BR /&gt;| fieldformat STARTTIME = strftime(NEW_START_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat ENDTIME = strftime(NEW_END_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;BR /&gt;| fieldformat NEXTTIME = strftime(NEW_NEXT_TIME + tonumber(offset), "%F %H:%M:%S (".TIMEZONE.")")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Dec 2022 11:39:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-convert-epoch-time-to-a-desired-time-zone/m-p/624122#M216976</guid>
      <dc:creator>sekhar463</dc:creator>
      <dc:date>2022-12-13T11:39:29Z</dc:date>
    </item>
  </channel>
</rss>

