<?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 Bucketing function in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31005#M6372</link>
    <description>&lt;P&gt;I Cant get this search to work as i wish.&lt;/P&gt;

&lt;P&gt;This is my search (timespan = -2h@h):&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=stats device_id=1352199920_8710631364 | bucket _time span=1h | table _time LogKb1521 LogKb57740 LogDelegateErr CountNoL7OptNFS CountPassIntSSL CountNoL7OptNotes LogKb1872 CountNoL7OptMSSQL CountPassCitrix LogKb1510
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;What i want is a search result telling me the summed events (yes, the fields are numerical) of each field with 2 samples. One for the events from -2h@h to -1h@h and another from -1h@h to @h&lt;/P&gt;

&lt;P&gt;What i do get is 31 results.&lt;/P&gt;

&lt;P&gt;Same result when using 'bins=2'&lt;/P&gt;

&lt;P&gt;When using 'minspan=1h', i get this error: "minspan option has no effect when span is specified"&lt;/P&gt;</description>
    <pubDate>Mon, 13 May 2013 11:42:03 GMT</pubDate>
    <dc:creator>polymorphic</dc:creator>
    <dc:date>2013-05-13T11:42:03Z</dc:date>
    <item>
      <title>Bucketing function</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31005#M6372</link>
      <description>&lt;P&gt;I Cant get this search to work as i wish.&lt;/P&gt;

&lt;P&gt;This is my search (timespan = -2h@h):&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=stats device_id=1352199920_8710631364 | bucket _time span=1h | table _time LogKb1521 LogKb57740 LogDelegateErr CountNoL7OptNFS CountPassIntSSL CountNoL7OptNotes LogKb1872 CountNoL7OptMSSQL CountPassCitrix LogKb1510
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;What i want is a search result telling me the summed events (yes, the fields are numerical) of each field with 2 samples. One for the events from -2h@h to -1h@h and another from -1h@h to @h&lt;/P&gt;

&lt;P&gt;What i do get is 31 results.&lt;/P&gt;

&lt;P&gt;Same result when using 'bins=2'&lt;/P&gt;

&lt;P&gt;When using 'minspan=1h', i get this error: "minspan option has no effect when span is specified"&lt;/P&gt;</description>
      <pubDate>Mon, 13 May 2013 11:42:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31005#M6372</guid>
      <dc:creator>polymorphic</dc:creator>
      <dc:date>2013-05-13T11:42:03Z</dc:date>
    </item>
    <item>
      <title>Re: Bucketing function</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31006#M6373</link>
      <description>&lt;P&gt;I don't think that the &lt;CODE&gt;bucket&lt;/CODE&gt; command is misbehaving - you probably have 31 events in total for that device_id for those 2 hours. &lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;table&lt;/CODE&gt; just lists the fields &lt;EM&gt;in each event&lt;/EM&gt;. So 31 events will give a table with 31 rows.&lt;/P&gt;

&lt;P&gt;What I &lt;EM&gt;think&lt;/EM&gt; you want is a &lt;CODE&gt;timechart&lt;/CODE&gt; with a &lt;CODE&gt;sum()&lt;/CODE&gt; for each field. Please note that the time constraints are added to the search below;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=stats device_id=1352199920_8710631364 earliest=-2h@h latest=@h | timechart span=1h sum(LogKb1521) sum(LogKb57740) sum(LogDelegateErr) sum(CountNoL7OptNFS) sum(CountPassIntSSL) sum(CountNoL7OptNotes) sum(LogKb1872) sum(CountNoL7OptMSSQL) sum(CountPassCitrix) sum(LogKb1510)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Hope this helps,&lt;/P&gt;

&lt;P&gt;Kristian&lt;/P&gt;</description>
      <pubDate>Mon, 13 May 2013 12:04:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31006#M6373</guid>
      <dc:creator>kristian_kolb</dc:creator>
      <dc:date>2013-05-13T12:04:00Z</dc:date>
    </item>
    <item>
      <title>Re: Bucketing function</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31007#M6374</link>
      <description>&lt;P&gt;Yes you are right.&lt;BR /&gt;
Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 13 May 2013 12:16:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31007#M6374</guid>
      <dc:creator>polymorphic</dc:creator>
      <dc:date>2013-05-13T12:16:25Z</dc:date>
    </item>
    <item>
      <title>Re: Bucketing function</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31008#M6375</link>
      <description>&lt;P&gt;you're welcome&lt;/P&gt;</description>
      <pubDate>Mon, 13 May 2013 12:24:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Bucketing-function/m-p/31008#M6375</guid>
      <dc:creator>kristian_kolb</dc:creator>
      <dc:date>2013-05-13T12:24:04Z</dc:date>
    </item>
  </channel>
</rss>

