<?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: Is there a way to format the _time field? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98022#M25274</link>
    <description>&lt;P&gt;I solved my own question, this worked:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype="mysource" | eval time=strftime(_time, "%m/%d/%y %I:%M:%S:%p") | table time field1 field2 field3
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Although I still think you should be able to format _time directly without the use of an eval &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 14 Oct 2013 20:59:19 GMT</pubDate>
    <dc:creator>echojacques</dc:creator>
    <dc:date>2013-10-14T20:59:19Z</dc:date>
    <item>
      <title>Is there a way to format the _time field?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98021#M25273</link>
      <description>&lt;P&gt;Is there a way to format the "_time" field?  I currently use _time in many of my dashboards and searches; however, it is formatted differently depending on the sourcetype.&lt;/P&gt;

&lt;P&gt;My attempt to standardize the output of _time below doesn't work:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype="mysource" | table _time("%m/%d/%y %I:%M:%S %p") field1 field2 field3
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Does anyone know how to do this?&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 14 Oct 2013 20:54:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98021#M25273</guid>
      <dc:creator>echojacques</dc:creator>
      <dc:date>2013-10-14T20:54:06Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to format the _time field?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98022#M25274</link>
      <description>&lt;P&gt;I solved my own question, this worked:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype="mysource" | eval time=strftime(_time, "%m/%d/%y %I:%M:%S:%p") | table time field1 field2 field3
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Although I still think you should be able to format _time directly without the use of an eval &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 14 Oct 2013 20:59:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98022#M25274</guid>
      <dc:creator>echojacques</dc:creator>
      <dc:date>2013-10-14T20:59:19Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to format the _time field?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98023#M25275</link>
      <description>&lt;P&gt;It's been my experience that &lt;CODE&gt;| table _time ...&lt;/CODE&gt; will format &lt;CODE&gt;_time&lt;/CODE&gt; into a sane value anyway.  At least directly in the search app.  It may act different in a dashboard.  But, if you want a specific time format your &lt;CODE&gt;strftime&lt;/CODE&gt; is a great approach.&lt;/P&gt;</description>
      <pubDate>Mon, 14 Oct 2013 21:33:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98023#M25275</guid>
      <dc:creator>dwaddle</dc:creator>
      <dc:date>2013-10-14T21:33:32Z</dc:date>
    </item>
    <item>
      <title>Re: Is there a way to format the _time field?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98024#M25276</link>
      <description>&lt;P&gt;I believe the implicit answer to the question is "No".&lt;BR /&gt;&lt;BR /&gt;
If you want to display _time the way you want, you have to do it in another field.&lt;/P&gt;</description>
      <pubDate>Wed, 10 Sep 2014 13:06:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-format-the-time-field/m-p/98024#M25276</guid>
      <dc:creator>manus</dc:creator>
      <dc:date>2014-09-10T13:06:53Z</dc:date>
    </item>
  </channel>
</rss>

