<?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 date format? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-to-convert-date-format/m-p/657061#M111259</link>
    <description>&lt;P&gt;Use the &lt;FONT face="courier new,courier"&gt;strptime&lt;/FONT&gt; function to convert the current format into epoch form then use &lt;FONT face="courier new,courier"&gt;strftime&lt;/FONT&gt; to convert that into the required format.&amp;nbsp; The two functions can be used in a single &lt;FONT face="courier new,courier"&gt;eval&lt;/FONT&gt;.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval timefield=strftime(strptime(timefield, "%d/%m/%y"), "%Y-%m-%d")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 08 Sep 2023 12:21:45 GMT</pubDate>
    <dc:creator>richgalloway</dc:creator>
    <dc:date>2023-09-08T12:21:45Z</dc:date>
    <item>
      <title>How to convert date format?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-convert-date-format/m-p/657056#M111257</link>
      <description>&lt;P&gt;Hi ,&lt;/P&gt;&lt;P&gt;In splunk query I need to convert date format as below .&lt;/P&gt;&lt;P&gt;Current format -&amp;nbsp;&lt;SPAN&gt;&lt;SPAN class=""&gt;07/09/23&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Required Format :&amp;nbsp;&lt;SPAN&gt;&lt;SPAN class=""&gt;2023-09-07&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 08 Sep 2023 11:14:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-convert-date-format/m-p/657056#M111257</guid>
      <dc:creator>dhiraj</dc:creator>
      <dc:date>2023-09-08T11:14:21Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert date format?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-convert-date-format/m-p/657059#M111258</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/260418"&gt;@dhiraj&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;you have to use the eval command with the strftime and strptime options, like this:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval new_date=strftime(strptime(date,"%d/0m/%y"),"%Y-%m-%d")&lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Fri, 08 Sep 2023 12:19:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-convert-date-format/m-p/657059#M111258</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2023-09-08T12:19:23Z</dc:date>
    </item>
    <item>
      <title>Re: How to convert date format?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-convert-date-format/m-p/657061#M111259</link>
      <description>&lt;P&gt;Use the &lt;FONT face="courier new,courier"&gt;strptime&lt;/FONT&gt; function to convert the current format into epoch form then use &lt;FONT face="courier new,courier"&gt;strftime&lt;/FONT&gt; to convert that into the required format.&amp;nbsp; The two functions can be used in a single &lt;FONT face="courier new,courier"&gt;eval&lt;/FONT&gt;.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval timefield=strftime(strptime(timefield, "%d/%m/%y"), "%Y-%m-%d")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 08 Sep 2023 12:21:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-convert-date-format/m-p/657061#M111259</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2023-09-08T12:21:45Z</dc:date>
    </item>
  </channel>
</rss>

