<?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: get total results per client per item for the last 7 days in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147499#M41225</link>
    <description>&lt;P&gt;Thanks for replying. For some reason I am getting the following error:&lt;/P&gt;

&lt;P&gt;Error in 'timechart' command: The argument 'itemSold' is invalid.&lt;/P&gt;

&lt;P&gt;sourcetype="itemSold.newIndex.stats" earliest=-7d@d | timechart span=1d count by clientId,  itemSold&lt;/P&gt;

&lt;P&gt;I'm not sure about your search query:&lt;/P&gt;

&lt;P&gt;mine just looks like this:&lt;/P&gt;

&lt;P&gt;source="/itemSold.newIndex/tcp/xxxx6"&lt;/P&gt;</description>
    <pubDate>Thu, 01 May 2014 13:51:01 GMT</pubDate>
    <dc:creator>jdepp</dc:creator>
    <dc:date>2014-05-01T13:51:01Z</dc:date>
    <item>
      <title>get total results per client per item for the last 7 days</title>
      <link>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147497#M41223</link>
      <description>&lt;P&gt;I would like to create a panel that displays in a table a historical records of counts for the last 7 days. The totals would be per client per item which follows this json format:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;  {"authorUrl":"michael_scooter","pubDate":"2014-04-30 11:27:49","clientId":"665",
  "itemSold":"((samsung TV))"}
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;So basically I would like to view the total counts of itemSold for each clientId for the last 7 days.Here is what i have now:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;search sourcetype="itemsSold.newIndex.stats"| timechart count by itemSold
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Apr 2014 15:31:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147497#M41223</guid>
      <dc:creator>jdepp</dc:creator>
      <dc:date>2014-04-30T15:31:45Z</dc:date>
    </item>
    <item>
      <title>Re: get total results per client per item for the last 7 days</title>
      <link>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147498#M41224</link>
      <description>&lt;P&gt;If with search&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype="itemsSold.newIndex.stats" | table _time, clientId, itemSold
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;You get output like&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;_time                clientId     itemSold
2014-04-30 11:27:49    665     ((samsung TV)) 
2014-04-30 11:29:49    669     ((apple TV))        -- example
....
....
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;&lt;STRONG&gt;Updated Query&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype="itemsSold.newIndex.stats" earliest=-7d@d | bucket span=1d _time | stats count by _time, clientId,itemSold
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;OR &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype="itemsSold.newIndex.stats" earliest=-7d@d | stats count by clientId, itemSold
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 30 Apr 2014 15:47:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147498#M41224</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2014-04-30T15:47:26Z</dc:date>
    </item>
    <item>
      <title>Re: get total results per client per item for the last 7 days</title>
      <link>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147499#M41225</link>
      <description>&lt;P&gt;Thanks for replying. For some reason I am getting the following error:&lt;/P&gt;

&lt;P&gt;Error in 'timechart' command: The argument 'itemSold' is invalid.&lt;/P&gt;

&lt;P&gt;sourcetype="itemSold.newIndex.stats" earliest=-7d@d | timechart span=1d count by clientId,  itemSold&lt;/P&gt;

&lt;P&gt;I'm not sure about your search query:&lt;/P&gt;

&lt;P&gt;mine just looks like this:&lt;/P&gt;

&lt;P&gt;source="/itemSold.newIndex/tcp/xxxx6"&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2014 13:51:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147499#M41225</guid>
      <dc:creator>jdepp</dc:creator>
      <dc:date>2014-05-01T13:51:01Z</dc:date>
    </item>
    <item>
      <title>Re: get total results per client per item for the last 7 days</title>
      <link>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147500#M41226</link>
      <description>&lt;P&gt;My bad, try the updated answer.&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2014 14:19:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147500#M41226</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2014-05-01T14:19:22Z</dc:date>
    </item>
    <item>
      <title>Re: get total results per client per item for the last 7 days</title>
      <link>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147501#M41227</link>
      <description>&lt;P&gt;you have been extremely helpful and I don't want to push my luck here but unfortunately its almost there but not quite. I think I need to see total itemSold for each clientId over 7 days within its own panel. That would make more sense, so I just need to break it down per clientID; so how do I code the limit: clientId = '665'&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2014 20:42:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147501#M41227</guid>
      <dc:creator>jdepp</dc:creator>
      <dc:date>2014-05-01T20:42:53Z</dc:date>
    </item>
    <item>
      <title>Re: get total results per client per item for the last 7 days</title>
      <link>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147502#M41228</link>
      <description>&lt;P&gt;Add the criteria in the base search. before first pipe.&lt;/P&gt;

&lt;P&gt;e.g.&lt;BR /&gt;
sourcetype="itemsSold.newIndex.stats" earliest=-7d@d clientId='665'| stats count by clientId, itemSold&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2014 21:18:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147502#M41228</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2014-05-01T21:18:46Z</dc:date>
    </item>
    <item>
      <title>Re: get total results per client per item for the last 7 days</title>
      <link>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147503#M41229</link>
      <description>&lt;P&gt;thanks got it.&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2014 21:31:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/get-total-results-per-client-per-item-for-the-last-7-days/m-p/147503#M41229</guid>
      <dc:creator>jdepp</dc:creator>
      <dc:date>2014-05-01T21:31:06Z</dc:date>
    </item>
  </channel>
</rss>

