<?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: Error with timechart command in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337343#M100069</link>
    <description>&lt;P&gt;@mahbs, as @mmodestino has pointed out timechart should have &lt;CODE&gt;span=1m&lt;/CODE&gt; not &lt;CODE&gt;span=avg("CPU")&lt;/CODE&gt;, please try out the following query:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;source="xxx.log" host="xxxl" index="xxx" sourcetype="xxx" earliest=$source_tok$ latest=$End_Date$ | eval ReportKey="Yesterday" |timechart span=1m avg("CPU") by ReportKey
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Refer to Splunk documentation and try and understand how &lt;CODE&gt;timechart&lt;/CODE&gt; command works: &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Timechart"&gt;http://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Timechart&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 30 Oct 2017 10:45:16 GMT</pubDate>
    <dc:creator>niketn</dc:creator>
    <dc:date>2017-10-30T10:45:16Z</dc:date>
    <item>
      <title>Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337336#M100062</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I'm having a bit of trouble with this query of mine. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;source="xxx" host="xxx" index="xxx" sourcetype="xxx" earliest=-1d@d latest=-0d@d | eval ReportKey="Yesterday"|timechart span= 1m avg("CPU") by ReportKey
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This is the error I'm getting:&lt;/P&gt;

&lt;P&gt;"Error in 'timechart' command: The specifier '1m' is invalid. It must be in form (). For example: max(size)."&lt;/P&gt;</description>
      <pubDate>Sun, 29 Oct 2017 22:00:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337336#M100062</guid>
      <dc:creator>mahbs</dc:creator>
      <dc:date>2017-10-29T22:00:05Z</dc:date>
    </item>
    <item>
      <title>Re: Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337337#M100063</link>
      <description>&lt;P&gt;try removing the space from your timechart command?&lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;..| timechart span=1m avg(CPU) by ReportKey&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 29 Oct 2017 22:56:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337337#M100063</guid>
      <dc:creator>mattymo</dc:creator>
      <dc:date>2017-10-29T22:56:09Z</dc:date>
    </item>
    <item>
      <title>Re: Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337338#M100064</link>
      <description>&lt;P&gt;Unfortunately it's not working. Im getting this error message now: The specifier '1m' is invalid. It must be in form (). For example: max(size)&lt;/P&gt;</description>
      <pubDate>Sun, 29 Oct 2017 22:59:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337338#M100064</guid>
      <dc:creator>mahbs</dc:creator>
      <dc:date>2017-10-29T22:59:29Z</dc:date>
    </item>
    <item>
      <title>Re: Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337339#M100065</link>
      <description>&lt;P&gt;can you post your updated search?&lt;/P&gt;</description>
      <pubDate>Mon, 30 Oct 2017 00:15:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337339#M100065</guid>
      <dc:creator>mattymo</dc:creator>
      <dc:date>2017-10-30T00:15:31Z</dc:date>
    </item>
    <item>
      <title>Re: Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337340#M100066</link>
      <description>&lt;P&gt;Your exmaple search seems ok. Just remove space, like..  &lt;CODE&gt;span= 1m&lt;/CODE&gt; to &lt;CODE&gt;span=1m&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;source="xxx.log" host="xxxl" index="xxx" sourcetype="xxx" earliest=$source_tok$ latest=$End_Date$ | eval ReportKey="Yesterday" |timechart span=1m avg("CPU") by ReportKey&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 16:30:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337340#M100066</guid>
      <dc:creator>kamlesh_vaghela</dc:creator>
      <dc:date>2020-09-29T16:30:42Z</dc:date>
    </item>
    <item>
      <title>Re: Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337341#M100067</link>
      <description>&lt;P&gt;yep, It's:&lt;/P&gt;

&lt;P&gt;source="xxx.log" host="xxxl" index="xxx" sourcetype="xxx" earliest=$source_tok$ latest=$End_Date$ | eval ReportKey="Yesterday" |timechart span=avg("CPU") by ReportKey&lt;/P&gt;

&lt;P&gt;I closed the space between the timespace and the pipe&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 16:30:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337341#M100067</guid>
      <dc:creator>mahbs</dc:creator>
      <dc:date>2020-09-29T16:30:50Z</dc:date>
    </item>
    <item>
      <title>Re: Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337342#M100068</link>
      <description>&lt;P&gt;I should add, the message I''m getting now is: &lt;/P&gt;

&lt;P&gt;Error in 'timechart' command: You must specify data field(s) to chart.&lt;/P&gt;</description>
      <pubDate>Mon, 30 Oct 2017 09:36:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337342#M100068</guid>
      <dc:creator>mahbs</dc:creator>
      <dc:date>2017-10-30T09:36:26Z</dc:date>
    </item>
    <item>
      <title>Re: Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337343#M100069</link>
      <description>&lt;P&gt;@mahbs, as @mmodestino has pointed out timechart should have &lt;CODE&gt;span=1m&lt;/CODE&gt; not &lt;CODE&gt;span=avg("CPU")&lt;/CODE&gt;, please try out the following query:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;source="xxx.log" host="xxxl" index="xxx" sourcetype="xxx" earliest=$source_tok$ latest=$End_Date$ | eval ReportKey="Yesterday" |timechart span=1m avg("CPU") by ReportKey
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Refer to Splunk documentation and try and understand how &lt;CODE&gt;timechart&lt;/CODE&gt; command works: &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Timechart"&gt;http://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Timechart&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 30 Oct 2017 10:45:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337343#M100069</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2017-10-30T10:45:16Z</dc:date>
    </item>
    <item>
      <title>Re: Error with timechart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337344#M100070</link>
      <description>&lt;P&gt;yeah, still got typos there. &lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;| timechart span=1m avg("CPU") by ReportKey&lt;/CODE&gt; Or you can leave span out and let Splunk automagically do it &lt;CODE&gt;| timechart avg("CPU") by ReportKey&lt;/CODE&gt; &lt;/P&gt;

&lt;P&gt;definitely check out the docs link below for syntax and examples!&lt;/P&gt;</description>
      <pubDate>Mon, 30 Oct 2017 12:25:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Error-with-timechart-command/m-p/337344#M100070</guid>
      <dc:creator>mattymo</dc:creator>
      <dc:date>2017-10-30T12:25:11Z</dc:date>
    </item>
  </channel>
</rss>

