<?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: Query to Display change in values of fields in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331431#M98613</link>
    <description>&lt;P&gt;Just extending @somesoni2 's Answer to your scenario.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;YourBaseSearch&amp;gt;
| rename * as Count*
| rename Count_time as _time
| rename Count_span as _span
| eval versions=0
| foreach Count* [eval versions=if(&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; &amp;gt; 0,versions+1,versions)]
| search versions&amp;gt;1
| fields - versions
| rename Count* as *
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 27 Jul 2017 16:07:27 GMT</pubDate>
    <dc:creator>niketn</dc:creator>
    <dc:date>2017-07-27T16:07:27Z</dc:date>
    <item>
      <title>Query to Display change in values of fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331428#M98610</link>
      <description>&lt;P&gt;I trying to write a query to check the changes in versions of a software. When using timechart (stacked) I can see multiple columns (when there was change in the version of software) and I am trying to display only those days which had occurrence of multiple columns in the graph. Any suggestions ?&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/3263i0042ECDD16F5FAEB/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jul 2017 11:07:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331428#M98610</guid>
      <dc:creator>muralianup</dc:creator>
      <dc:date>2017-07-27T11:07:55Z</dc:date>
    </item>
    <item>
      <title>Re: Query to Display change in values of fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331429#M98611</link>
      <description>&lt;P&gt;Can you share your query? Without knowing that, my suggestion would be to add following to your existing search.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;your current search producing above output
| eval versions=0
| foreach * [eval versions=if('&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;' &amp;gt; 0,versions+1,versions)]
| where versions&amp;gt;1 | fields -versions
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 27 Jul 2017 12:22:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331429#M98611</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2017-07-27T12:22:22Z</dc:date>
    </item>
    <item>
      <title>Re: Query to Display change in values of fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331430#M98612</link>
      <description>&lt;P&gt;Base query is index=web_prxy domain=abc useragent= | rex filed=useragent "(?P[\d]*)" | timechart count by Version limit=5&lt;/P&gt;

&lt;P&gt;Does stereamstats helps ? &lt;/P&gt;</description>
      <pubDate>Thu, 27 Jul 2017 12:34:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331430#M98612</guid>
      <dc:creator>muralianup</dc:creator>
      <dc:date>2017-07-27T12:34:29Z</dc:date>
    </item>
    <item>
      <title>Re: Query to Display change in values of fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331431#M98613</link>
      <description>&lt;P&gt;Just extending @somesoni2 's Answer to your scenario.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;YourBaseSearch&amp;gt;
| rename * as Count*
| rename Count_time as _time
| rename Count_span as _span
| eval versions=0
| foreach Count* [eval versions=if(&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; &amp;gt; 0,versions+1,versions)]
| search versions&amp;gt;1
| fields - versions
| rename Count* as *
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 27 Jul 2017 16:07:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331431#M98613</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2017-07-27T16:07:27Z</dc:date>
    </item>
    <item>
      <title>Re: Query to Display change in values of fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331432#M98614</link>
      <description>&lt;P&gt;The streamstats command helped. Borrowed the concept from one of the Splunk blog entries (on tracking DHCP lease for a particular MAC id).&lt;/P&gt;

&lt;P&gt;| streamstats current=false last(Version) as new_Version last(_time) AS time_of_change BY src_ip | where Version!=new_Version | convert ctime(time_of_change) AS time_of_change | rename Version as old_Version  | stats count by date_wday&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 15:11:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331432#M98614</guid>
      <dc:creator>muralianup</dc:creator>
      <dc:date>2020-09-29T15:11:57Z</dc:date>
    </item>
    <item>
      <title>Re: Query to Display change in values of fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331433#M98615</link>
      <description>&lt;P&gt;@muralianup, please accept your Answer to mark the question as answered.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Aug 2017 10:25:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Query-to-Display-change-in-values-of-fields/m-p/331433#M98615</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2017-08-03T10:25:34Z</dc:date>
    </item>
  </channel>
</rss>

