<?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: What is the best way to number each event in descending time? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/What-is-the-best-way-to-number-each-event-in-descending-time/m-p/402526#M167351</link>
    <description>&lt;P&gt;If you don't want to sort, then you can use tail  before streamstats.&lt;BR /&gt;
By default 10 gives 10 event count, if you have an idea about the maximum number of events in that time frame you can use that (eg. tail 100000)&lt;/P&gt;</description>
    <pubDate>Fri, 28 Sep 2018 16:19:21 GMT</pubDate>
    <dc:creator>Vijeta</dc:creator>
    <dc:date>2018-09-28T16:19:21Z</dc:date>
    <item>
      <title>What is the best way to number each event in descending time?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/What-is-the-best-way-to-number-each-event-in-descending-time/m-p/402524#M167349</link>
      <description>&lt;P&gt;I need to assign number each event sorted in decending _time order.&lt;/P&gt;

&lt;P&gt;Ex&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Event.     _time                  Count
Event1.      11:54:51.           1
Event2.      11:53:57            2
Event3.      11:53:52.           3
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I can use &lt;CODE&gt;|streamstats&lt;/CODE&gt; count.&lt;/P&gt;

&lt;P&gt;But does this guarantee events in descending order for historical searches on clustered indexers? Using sorting on _time is effecting query performance. So Is there any way to assign a increment number count based on descending order of _time.&lt;/P&gt;</description>
      <pubDate>Fri, 28 Sep 2018 11:00:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/What-is-the-best-way-to-number-each-event-in-descending-time/m-p/402524#M167349</guid>
      <dc:creator>ankithreddy777</dc:creator>
      <dc:date>2018-09-28T11:00:12Z</dc:date>
    </item>
    <item>
      <title>Re: What is the best way to number each event in descending time?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/What-is-the-best-way-to-number-each-event-in-descending-time/m-p/402525#M167350</link>
      <description>&lt;P&gt;hi @ankithreddy777&lt;/P&gt;

&lt;P&gt;can you try before &lt;CODE&gt;|sort - _time&lt;/CODE&gt; before &lt;STRONG&gt;streamstats&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Sep 2018 11:19:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/What-is-the-best-way-to-number-each-event-in-descending-time/m-p/402525#M167350</guid>
      <dc:creator>harishalipaka</dc:creator>
      <dc:date>2018-09-28T11:19:52Z</dc:date>
    </item>
    <item>
      <title>Re: What is the best way to number each event in descending time?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/What-is-the-best-way-to-number-each-event-in-descending-time/m-p/402526#M167351</link>
      <description>&lt;P&gt;If you don't want to sort, then you can use tail  before streamstats.&lt;BR /&gt;
By default 10 gives 10 event count, if you have an idea about the maximum number of events in that time frame you can use that (eg. tail 100000)&lt;/P&gt;</description>
      <pubDate>Fri, 28 Sep 2018 16:19:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/What-is-the-best-way-to-number-each-event-in-descending-time/m-p/402526#M167351</guid>
      <dc:creator>Vijeta</dc:creator>
      <dc:date>2018-09-28T16:19:21Z</dc:date>
    </item>
  </channel>
</rss>

