<?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: Why does the date format in scheduled csv report change in an email? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453972#M78605</link>
    <description>&lt;P&gt;Thanks, will see how it goes!&lt;/P&gt;</description>
    <pubDate>Tue, 20 Aug 2019 08:38:40 GMT</pubDate>
    <dc:creator>mcastino</dc:creator>
    <dc:date>2019-08-20T08:38:40Z</dc:date>
    <item>
      <title>Why does the date format in scheduled csv report change in an email?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453970#M78603</link>
      <description>&lt;P&gt;I have made a scheduled report which emails a csv file containing counts of particular events for each day in the last seven days.&lt;/P&gt;

&lt;P&gt;The format looks a little like this:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Date  -              X,    Y,   Z&lt;BR /&gt;
2019-08-12 -   5,    6,    8&lt;BR /&gt;
2019-08-13 -   10,  8,    7&lt;BR /&gt;
2019-08-14 -    2,    1,    1&lt;/STRONG&gt;                    &lt;/P&gt;

&lt;P&gt;The output in the Splunk UI shows dates correctly (  &lt;CODE&gt;| fieldformat Date= strftime(Date, "%Y-%m-%d"&lt;/CODE&gt; ), and when I download a CSV report manually the dates also look fine.&lt;/P&gt;

&lt;P&gt;However, in the scheduled report sent via email, dates are presented as below:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Date&lt;BR /&gt;
1565532000&lt;BR /&gt;
1565618400&lt;BR /&gt;
1565704800&lt;BR /&gt;
1565791200&lt;BR /&gt;
1565877600&lt;BR /&gt;
1565964000&lt;BR /&gt;
1566050400&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;Any thoughts on what's going on here?&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 20 Aug 2019 01:55:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453970#M78603</guid>
      <dc:creator>mcastino</dc:creator>
      <dc:date>2019-08-20T01:55:41Z</dc:date>
    </item>
    <item>
      <title>Re: Why does the date format in scheduled csv report change in an email?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453971#M78604</link>
      <description>&lt;P&gt;The actual data is still an integer.  Generally you should be using &lt;CODE&gt;fieldformat&lt;/CODE&gt; the way that you are, but if the output is going to be exported and you need human-readable dates, then swap &lt;CODE&gt;fieldformat&lt;/CODE&gt; for &lt;CODE&gt;eval&lt;/CODE&gt; like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | eval Date=strftime(Date, "%Y-%m-%d")
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 20 Aug 2019 05:36:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453971#M78604</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-08-20T05:36:15Z</dc:date>
    </item>
    <item>
      <title>Re: Why does the date format in scheduled csv report change in an email?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453972#M78605</link>
      <description>&lt;P&gt;Thanks, will see how it goes!&lt;/P&gt;</description>
      <pubDate>Tue, 20 Aug 2019 08:38:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453972#M78605</guid>
      <dc:creator>mcastino</dc:creator>
      <dc:date>2019-08-20T08:38:40Z</dc:date>
    </item>
    <item>
      <title>Re: Why does the date format in scheduled csv report change in an email?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453973#M78606</link>
      <description>&lt;P&gt;Come back and let us know how it went and click &lt;CODE&gt;Accept&lt;/CODE&gt; to close the question.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Sep 2019 14:12:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Why-does-the-date-format-in-scheduled-csv-report-change-in-an/m-p/453973#M78606</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-09-03T14:12:19Z</dc:date>
    </item>
  </channel>
</rss>

