<?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: How to filter the search with the following record in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545493#M154520</link>
    <description>&lt;P&gt;The last two lines in that example were what you need to use in your query, obviously you will have to tweak the variable names according to your data if they are not as you have indicated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 25 Mar 2021 22:28:09 GMT</pubDate>
    <dc:creator>bowesmana</dc:creator>
    <dc:date>2021-03-25T22:28:09Z</dc:date>
    <item>
      <title>How to filter the search with the following record</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545244#M154414</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;Can I know how to get the record from ver 1.1 by case sensitive excluding record from ver 1.2?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Currently I have data like this:&lt;/P&gt;&lt;P&gt;records:&lt;/P&gt;&lt;P&gt;============================================&lt;/P&gt;&lt;P&gt;index=a, ver=1.1, a="halo", b="haha", c="nana"&lt;/P&gt;&lt;P&gt;index=a, ver=1.1, a="testing", b="haha", c="nana"&lt;/P&gt;&lt;P&gt;index=a, ver=1.1, a="halo", b="kaka", c="testing"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;index=a, ver=1.2, a="halo", b="haha", c="nana"&lt;/P&gt;&lt;P&gt;index=a, ver=1.2, a="lala", b="haha", c="nana"&lt;/P&gt;&lt;P&gt;index=a, ver=1.2, a="halo", b="kaka", c="TESTING"&lt;/P&gt;&lt;P&gt;============================================&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Result expected:&lt;/P&gt;&lt;P&gt;index=a, ver=1.1, a="testing", b="haha", c="nana"&lt;/P&gt;&lt;P&gt;index=a, ver=1.1, a="halo", b="kaka", c="testing"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is that possible to be done?&lt;/P&gt;</description>
      <pubDate>Thu, 25 Mar 2021 01:36:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545244#M154414</guid>
      <dc:creator>zhanweiw</dc:creator>
      <dc:date>2021-03-25T01:36:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter the search with the following record</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545261#M154416</link>
      <description>&lt;P&gt;This is a run anywhere example using your data&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| makeresults
| eval x="index=a, ver=1.1, a=\"halo\", b=\"haha\", c=\"nana\"##index=a, ver=1.1, a=\"testing\", b=\"haha\", c=\"nana\"##index=a, ver=1.1, a=\"halo\", b=\"kaka\", c=\"testing\"##index=a, ver=1.2, a=\"halo\", b=\"haha\", c=\"nana\"##index=a, ver=1.2, a=\"lala\", b=\"haha\", c=\"nana\"##index=a, ver=1.2, a=\"halo\", b=\"kaka\", c=\"TESTING\""
| makemv delim="##" x
| mvexpand x
| table x
| rename x as _raw
| extract
| fields - _raw
| stats values(ver) as ver by index a b c
| where ver="1.1" AND mvcount(ver)=1&lt;/LI-CODE&gt;&lt;P&gt;The last two lines are the ones you want - and this is collapsing the versions for each of the&amp;nbsp; index/a/b/c combinations and then just checking that ver only contains 1.1&lt;/P&gt;&lt;P&gt;Hope this helps&lt;/P&gt;</description>
      <pubDate>Thu, 25 Mar 2021 06:06:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545261#M154416</guid>
      <dc:creator>bowesmana</dc:creator>
      <dc:date>2021-03-25T06:06:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter the search with the following record</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545290#M154423</link>
      <description>&lt;P&gt;Hi bowesmana,&lt;/P&gt;&lt;P&gt;thank you for your answer, it works as expected.&lt;/P&gt;&lt;P&gt;However, I have pushed these records to Splunk database.&lt;/P&gt;&lt;P&gt;If I want to get the data from Splunk database and produce the same result, what query should I form?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 25 Mar 2021 08:04:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545290#M154423</guid>
      <dc:creator>zhanweiw</dc:creator>
      <dc:date>2021-03-25T08:04:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter the search with the following record</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545493#M154520</link>
      <description>&lt;P&gt;The last two lines in that example were what you need to use in your query, obviously you will have to tweak the variable names according to your data if they are not as you have indicated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 25 Mar 2021 22:28:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545493#M154520</guid>
      <dc:creator>bowesmana</dc:creator>
      <dc:date>2021-03-25T22:28:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter the search with the following record</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545501#M154523</link>
      <description>&lt;P&gt;Hi Bowesmana,&lt;/P&gt;&lt;P&gt;I understood now.&lt;/P&gt;&lt;P&gt;Thank you for your help.&lt;/P&gt;&lt;P&gt;The last two lines are what I needed:&lt;/P&gt;&lt;P&gt;| stats values(ver) as ver by index a b c&lt;/P&gt;&lt;P&gt;| where ver="1.1" AND mvcount(ver) = 1&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 25 Mar 2021 23:54:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-filter-the-search-with-the-following-record/m-p/545501#M154523</guid>
      <dc:creator>zhanweiw</dc:creator>
      <dc:date>2021-03-25T23:54:25Z</dc:date>
    </item>
  </channel>
</rss>

