<?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 How do I format my date/time in a CSV file so that Splunk will recognize it as a timestamp? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-format-my-date-time-in-a-CSV-file-so-that-Splunk-will/m-p/203868#M40244</link>
    <description>&lt;P&gt;I've tried &lt;CODE&gt;Time_Format= %m/%d/%y %h:%m&lt;/CODE&gt; and i still get a parsing error saying it can't parse &lt;CODE&gt;12/01/2015 0:00&lt;/CODE&gt; which makes no sense because that's exactly as it should be parsed. Any suggestions on what I may be missing? I want to change in my CSV before I upload into Splunk. I've tried changing to date, time, general, everything. It's so basic, I can't see what Splunk's issue is. &lt;/P&gt;

&lt;P&gt;Sample:&lt;BR /&gt;
Date    Acct_Number Employee_Id Case_Id Status_Desc&lt;BR /&gt;
12/1/15 0:00    233657933201    937018  C105138792  CLOSED&lt;BR /&gt;
12/1/15 0:00    231218910100    851905  C105145259  CLOSED&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 08:48:40 GMT</pubDate>
    <dc:creator>mecrass</dc:creator>
    <dc:date>2020-09-29T08:48:40Z</dc:date>
    <item>
      <title>How do I format my date/time in a CSV file so that Splunk will recognize it as a timestamp?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-format-my-date-time-in-a-CSV-file-so-that-Splunk-will/m-p/203868#M40244</link>
      <description>&lt;P&gt;I've tried &lt;CODE&gt;Time_Format= %m/%d/%y %h:%m&lt;/CODE&gt; and i still get a parsing error saying it can't parse &lt;CODE&gt;12/01/2015 0:00&lt;/CODE&gt; which makes no sense because that's exactly as it should be parsed. Any suggestions on what I may be missing? I want to change in my CSV before I upload into Splunk. I've tried changing to date, time, general, everything. It's so basic, I can't see what Splunk's issue is. &lt;/P&gt;

&lt;P&gt;Sample:&lt;BR /&gt;
Date    Acct_Number Employee_Id Case_Id Status_Desc&lt;BR /&gt;
12/1/15 0:00    233657933201    937018  C105138792  CLOSED&lt;BR /&gt;
12/1/15 0:00    231218910100    851905  C105145259  CLOSED&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 08:48:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-format-my-date-time-in-a-CSV-file-so-that-Splunk-will/m-p/203868#M40244</guid>
      <dc:creator>mecrass</dc:creator>
      <dc:date>2020-09-29T08:48:40Z</dc:date>
    </item>
    <item>
      <title>Re: How do I format my date/time in a CSV file so that Splunk will recognize it as a timestamp?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-format-my-date-time-in-a-CSV-file-so-that-Splunk-will/m-p/203869#M40245</link>
      <description>&lt;P&gt;I had to fix this in some logs a long time ago, and I did so by editing the $splunkhome/etc/datetime.xml.&lt;/P&gt;

&lt;P&gt;There's a section like this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;define name="_hour" extract="hour"&amp;gt;
    &amp;lt;text&amp;gt;&amp;lt;![CDATA[([01]?[1-9]|[012][0-3])(?!\d)]]&amp;gt;&amp;lt;/text&amp;gt;
&amp;lt;/define&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Change the &lt;CODE&gt;[1-9]&lt;/CODE&gt; in the middle to &lt;CODE&gt;[0-9]&lt;/CODE&gt; like this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;define name="_hour" extract="hour"&amp;gt;
    &amp;lt;text&amp;gt;&amp;lt;![CDATA[([01]?[0-9]|[012][0-3])(?!\d)]]&amp;gt;&amp;lt;/text&amp;gt;
&amp;lt;/define&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Let us know if that fixed your problem!  (It certainly made the test CSV I created with your data in it seem to get properly parsed, so it should be good).&lt;/P&gt;</description>
      <pubDate>Mon, 15 Feb 2016 22:08:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-format-my-date-time-in-a-CSV-file-so-that-Splunk-will/m-p/203869#M40245</guid>
      <dc:creator>Richfez</dc:creator>
      <dc:date>2016-02-15T22:08:32Z</dc:date>
    </item>
  </channel>
</rss>

