<?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 do I search results that depend on the subsearch being empty? in Monitoring Splunk</title>
    <link>https://community.splunk.com/t5/Monitoring-Splunk/How-do-I-search-results-that-depend-on-the-subsearch-being-empty/m-p/404722#M6526</link>
    <description>&lt;P&gt;Like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=mlbso sourcetype=BWP_hanatraces earliest=1543313122.531 latest=1543313122.537
[search index=mlbso sourcetype=BWP_hanatraces  "ALTER SYSTEM ALTER CONFIGURATION" earliest=1543313122.531 latest=1543313122.537
| rex field=_raw "(?i)(?&amp;lt;=configuration is changed by )(?P&amp;lt;CONNECTION_ID&amp;gt;(?s)(.*))(?=, client ip)"
| appendpipe [|makeresults | eval CONNECTION_ID="THIS_STRING_WILL_NOT_BE_IN_ANY_OF_YOUR_EVENTS"]
| head 1
| return $CONNECTION_ID]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Wed, 19 Dec 2018 22:57:19 GMT</pubDate>
    <dc:creator>woodcock</dc:creator>
    <dc:date>2018-12-19T22:57:19Z</dc:date>
    <item>
      <title>How do I search results that depend on the subsearch being empty?</title>
      <link>https://community.splunk.com/t5/Monitoring-Splunk/How-do-I-search-results-that-depend-on-the-subsearch-being-empty/m-p/404721#M6525</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;

&lt;P&gt;I have following search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=mlbso sourcetype=BWP_hanatraces earliest=1543313122.531 latest=1543313122.537 [search index=mlbso sourcetype=BWP_hanatraces  "ALTER SYSTEM ALTER CONFIGURATION" earliest=1543313122.531 latest=1543313122.537 | rex field=_raw "(?i)(?&amp;lt;=configuration is changed by )(?P&amp;lt;CONNECTION_ID&amp;gt;(?s)(.*))(?=, client ip)" | return $CONNECTION_ID]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Now, it works fine when the subsearch returns a value back to the outer search. &lt;/P&gt;

&lt;P&gt;However when the subsearch does not return anything back (no proper value is found) then the outer search is not restricted with the subsearch and it returns too many events.&lt;/P&gt;

&lt;P&gt;How would I achieve the whole search returning no events based on the subsearch being empty?&lt;/P&gt;

&lt;P&gt;Kind Regards,&lt;BR /&gt;
Kamil    &lt;/P&gt;</description>
      <pubDate>Tue, 27 Nov 2018 15:25:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Monitoring-Splunk/How-do-I-search-results-that-depend-on-the-subsearch-being-empty/m-p/404721#M6525</guid>
      <dc:creator>damucka</dc:creator>
      <dc:date>2018-11-27T15:25:32Z</dc:date>
    </item>
    <item>
      <title>Re: How do I search results that depend on the subsearch being empty?</title>
      <link>https://community.splunk.com/t5/Monitoring-Splunk/How-do-I-search-results-that-depend-on-the-subsearch-being-empty/m-p/404722#M6526</link>
      <description>&lt;P&gt;Like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=mlbso sourcetype=BWP_hanatraces earliest=1543313122.531 latest=1543313122.537
[search index=mlbso sourcetype=BWP_hanatraces  "ALTER SYSTEM ALTER CONFIGURATION" earliest=1543313122.531 latest=1543313122.537
| rex field=_raw "(?i)(?&amp;lt;=configuration is changed by )(?P&amp;lt;CONNECTION_ID&amp;gt;(?s)(.*))(?=, client ip)"
| appendpipe [|makeresults | eval CONNECTION_ID="THIS_STRING_WILL_NOT_BE_IN_ANY_OF_YOUR_EVENTS"]
| head 1
| return $CONNECTION_ID]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 19 Dec 2018 22:57:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Monitoring-Splunk/How-do-I-search-results-that-depend-on-the-subsearch-being-empty/m-p/404722#M6526</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2018-12-19T22:57:19Z</dc:date>
    </item>
  </channel>
</rss>

