<?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: Same query run multiple times returns different results in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481026#M134788</link>
    <description>&lt;P&gt;Download the &lt;CODE&gt;Meta Woot!&lt;/CODE&gt; app and it will make it easy to see.&lt;/P&gt;</description>
    <pubDate>Sun, 15 Sep 2019 19:20:01 GMT</pubDate>
    <dc:creator>woodcock</dc:creator>
    <dc:date>2019-09-15T19:20:01Z</dc:date>
    <item>
      <title>Same query run multiple times returns different results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481022#M134784</link>
      <description>&lt;P&gt;I got a different result count when I executed this query a week before, and when I executed it today. The first time, the query returned 16 records, today, it returned 21! How is this possible? I ran the search for the same absolute time period both times. If it helps, I experienced similar inconsistent results with another query on the same search head. There are no errors in the search results that could point to any suppressed events:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;servername=abc* sourcetype=bq
| rex "java\.\S+\.(?P&amp;lt;Var1&amp;gt;[ A-Z]+(Err))"
| rex field=_raw "(?&amp;lt;Var2&amp;gt;com\.jss\S*\.\S+)\.[A-Z]\S+\((?&amp;lt;Var3&amp;gt;\w+)\.java:(?&amp;lt;Var4&amp;gt;\d+)\)"
| search Var1=NNN
| eval Var3=coalesce(Var3, "No Var3"), Var4=coalesce(Var4, "No Var4"), Var3=Var3. "." .Var4
| search Var3=*
| stats count by Var1, Var3, Var2
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I have already spent many hours trying to troubleshoot this, so any pointers would be very helpful. Thank you!&lt;/P&gt;</description>
      <pubDate>Sun, 15 Sep 2019 01:50:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481022#M134784</guid>
      <dc:creator>rey123</dc:creator>
      <dc:date>2019-09-15T01:50:41Z</dc:date>
    </item>
    <item>
      <title>Re: Same query run multiple times returns different results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481023#M134785</link>
      <description>&lt;P&gt;Tagging @somesoni2, @woodcock as they have been very helpful with such questions before and this is a little urgent. Thank you&lt;/P&gt;

&lt;P&gt;P.S. - This is on Splunk Enterprise v7.1.6&lt;/P&gt;</description>
      <pubDate>Sun, 15 Sep 2019 03:04:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481023#M134785</guid>
      <dc:creator>rey123</dc:creator>
      <dc:date>2019-09-15T03:04:52Z</dc:date>
    </item>
    <item>
      <title>Re: Same query run multiple times returns different results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481024#M134786</link>
      <description>&lt;P&gt;This is 1 of 2 problems:&lt;BR /&gt;
1: The events are arriving late.  Sometimes the box is completely off, or offline, or Splunk is not running and then it comes back and the events come flooding in late.&lt;BR /&gt;
2: If you are using an accelerated datamodel, this usually runs behind about 3 minutes but sometimes WAY more than that, especially if you rest it.&lt;BR /&gt;
You can compare &lt;CODE&gt;_indextime&lt;/CODE&gt; against &lt;CODE&gt;_time&lt;/CODE&gt; to differentiate between the 2.&lt;/P&gt;</description>
      <pubDate>Sun, 15 Sep 2019 15:31:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481024#M134786</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-09-15T15:31:26Z</dc:date>
    </item>
    <item>
      <title>Re: Same query run multiple times returns different results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481025#M134787</link>
      <description>&lt;P&gt;Thank you for your reply, @woodcock, would you mind sharing how I could compare &lt;CODE&gt;_indextime&lt;/CODE&gt; against &lt;CODE&gt;_time&lt;/CODE&gt;? Do I remove the &lt;CODE&gt;stats&lt;/CODE&gt; statement at the end of my query and simply append  &lt;CODE&gt;_indextime&lt;/CODE&gt; and &lt;CODE&gt;_time&lt;/CODE&gt; to the &lt;CODE&gt;search&lt;/CODE&gt; statement? Thanks!&lt;/P&gt;</description>
      <pubDate>Sun, 15 Sep 2019 17:38:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481025#M134787</guid>
      <dc:creator>rey123</dc:creator>
      <dc:date>2019-09-15T17:38:14Z</dc:date>
    </item>
    <item>
      <title>Re: Same query run multiple times returns different results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481026#M134788</link>
      <description>&lt;P&gt;Download the &lt;CODE&gt;Meta Woot!&lt;/CODE&gt; app and it will make it easy to see.&lt;/P&gt;</description>
      <pubDate>Sun, 15 Sep 2019 19:20:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481026#M134788</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-09-15T19:20:01Z</dc:date>
    </item>
    <item>
      <title>Re: Same query run multiple times returns different results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481027#M134789</link>
      <description>&lt;P&gt;Thanks, can this be installed by someone who's not a Splunk Admin? From a quick online check, it seemed not, but maybe I'm mistaken.&lt;/P&gt;</description>
      <pubDate>Sun, 15 Sep 2019 19:31:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Same-query-run-multiple-times-returns-different-results/m-p/481027#M134789</guid>
      <dc:creator>rey123</dc:creator>
      <dc:date>2019-09-15T19:31:29Z</dc:date>
    </item>
  </channel>
</rss>

