<?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: VALUE FORMAT in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448185#M168259</link>
    <description>&lt;P&gt;Hey@jip31,&lt;/P&gt;

&lt;P&gt;You can add these attributes in your props.conf:&lt;BR /&gt;
&lt;A href="https://docs.splunk.com/Documentation/Splunk/7.1.2/Admin/Propsconf" target="_blank"&gt;https://docs.splunk.com/Documentation/Splunk/7.1.2/Admin/Propsconf&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;TIME_FORMAT = &lt;BR /&gt;
TIME_PREFIX = &lt;/P&gt;

&lt;P&gt;Let me know if this helps!!&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 20:33:03 GMT</pubDate>
    <dc:creator>deepashri_123</dc:creator>
    <dc:date>2020-09-29T20:33:03Z</dc:date>
    <item>
      <title>VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448184#M168258</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;

&lt;P&gt;i have a value like this in a field 2018067155420 and i want to format it with this format : yyyymmddhhmmss so&lt;BR /&gt;
could you help me please??&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jul 2018 06:25:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448184#M168258</guid>
      <dc:creator>jip31</dc:creator>
      <dc:date>2018-07-19T06:25:27Z</dc:date>
    </item>
    <item>
      <title>Re: VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448185#M168259</link>
      <description>&lt;P&gt;Hey@jip31,&lt;/P&gt;

&lt;P&gt;You can add these attributes in your props.conf:&lt;BR /&gt;
&lt;A href="https://docs.splunk.com/Documentation/Splunk/7.1.2/Admin/Propsconf" target="_blank"&gt;https://docs.splunk.com/Documentation/Splunk/7.1.2/Admin/Propsconf&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;TIME_FORMAT = &lt;BR /&gt;
TIME_PREFIX = &lt;/P&gt;

&lt;P&gt;Let me know if this helps!!&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:33:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448185#M168259</guid>
      <dc:creator>deepashri_123</dc:creator>
      <dc:date>2020-09-29T20:33:03Z</dc:date>
    </item>
    <item>
      <title>Re: VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448186#M168260</link>
      <description>&lt;P&gt;hi&lt;BR /&gt;
not really&lt;BR /&gt;
i just want to format this value&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jul 2018 09:25:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448186#M168260</guid>
      <dc:creator>jip31</dc:creator>
      <dc:date>2018-07-19T09:25:45Z</dc:date>
    </item>
    <item>
      <title>Re: VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448187#M168261</link>
      <description>&lt;P&gt;What do you mean by format this value? Can you give an example of the output you expect of that formatting?&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jul 2018 10:14:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448187#M168261</guid>
      <dc:creator>FrankVl</dc:creator>
      <dc:date>2018-07-19T10:14:03Z</dc:date>
    </item>
    <item>
      <title>Re: VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448188#M168262</link>
      <description>&lt;P&gt;hi&lt;BR /&gt;
This value 20180627155420 correspond to the date 2018 06 27 and the hour 15 54 20&lt;BR /&gt;
i would like to have finally an EVAL which does 27/06/2018 15:54&lt;BR /&gt;
thanks&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jul 2018 11:30:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448188#M168262</guid>
      <dc:creator>jip31</dc:creator>
      <dc:date>2018-07-19T11:30:44Z</dc:date>
    </item>
    <item>
      <title>Re: VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448189#M168263</link>
      <description>&lt;P&gt;Try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| makeresults
| eval date_time = 20180627155420
| eval formatted_date_time = strftime(strptime(date_time,"%Y%m%d%H%M%S"),"%d/%m/%Y %H:%M")
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;First two lines are just to generate an example, you only need the last line (make sure to adjust the field names to your situation). This code parses the date-time string that you have to a unix timestamp, and then prints that timestamp as per the format you wanted.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jul 2018 11:43:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448189#M168263</guid>
      <dc:creator>FrankVl</dc:creator>
      <dc:date>2018-07-19T11:43:16Z</dc:date>
    </item>
    <item>
      <title>Re: VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448190#M168264</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;

&lt;P&gt;i have wrote this but it doesnt works&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="windows-wmi" sourcetype="WMI:LastLogon" LastLogon | rex field=LastLogon mode=sed "s/\..*$//" | eval LastLogon = strftime(strptime(date_time,"%Y%m%d%H%M%S"),"%d/%m/%Y %H:%M")
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;there is a mistake somewhere??&lt;/P&gt;</description>
      <pubDate>Fri, 20 Jul 2018 07:26:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448190#M168264</guid>
      <dc:creator>jip31</dc:creator>
      <dc:date>2018-07-20T07:26:44Z</dc:date>
    </item>
    <item>
      <title>Re: VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448191#M168265</link>
      <description>&lt;P&gt;Yes, like I said, you need to adjust it to your field names. So replace date_time with the field that contains your input. So looking at your example that would be LastLogon.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; index="windows-wmi" sourcetype="WMI:LastLogon" LastLogon | rex field=LastLogon mode=sed "s/\..*$//" | eval LastLogon = strftime(strptime(LastLogon,"%Y%m%d%H%M%S"),"%d/%m/%Y %H:%M")
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 20 Jul 2018 07:47:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448191#M168265</guid>
      <dc:creator>FrankVl</dc:creator>
      <dc:date>2018-07-20T07:47:53Z</dc:date>
    </item>
    <item>
      <title>Re: VALUE FORMAT</title>
      <link>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448192#M168266</link>
      <description>&lt;P&gt;you are the best! thanks&lt;/P&gt;</description>
      <pubDate>Fri, 20 Jul 2018 07:57:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/VALUE-FORMAT/m-p/448192#M168266</guid>
      <dc:creator>jip31</dc:creator>
      <dc:date>2018-07-20T07:57:12Z</dc:date>
    </item>
  </channel>
</rss>

