<?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 Where with subsearch in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Where-with-subsearch/m-p/349325#M103428</link>
    <description>&lt;P&gt;Hi All,&lt;/P&gt;

&lt;P&gt;I am trying correlate 2 different search queries using  where with subsearch&lt;BR /&gt;
it goes like this:&lt;/P&gt;

&lt;P&gt;host="host1" | table Value1&lt;BR /&gt;
above search give result : 40&lt;/P&gt;

&lt;P&gt;host="host2" | where Value2&amp;lt;40&lt;BR /&gt;
above search gives a list of events&lt;/P&gt;

&lt;P&gt;But when I use above two in one search query like:&lt;BR /&gt;
host="host2" | where Value2&amp;gt;[host="host1" | table Value1]&lt;/P&gt;

&lt;P&gt;it's giving error : Error in 'where' command: Typechecking failed. The '&amp;lt;' operator received different types.&lt;/P&gt;

&lt;P&gt;Kindly help!&lt;/P&gt;</description>
    <pubDate>Wed, 18 Apr 2018 20:53:51 GMT</pubDate>
    <dc:creator>nkankur</dc:creator>
    <dc:date>2018-04-18T20:53:51Z</dc:date>
    <item>
      <title>Where with subsearch</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Where-with-subsearch/m-p/349325#M103428</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;

&lt;P&gt;I am trying correlate 2 different search queries using  where with subsearch&lt;BR /&gt;
it goes like this:&lt;/P&gt;

&lt;P&gt;host="host1" | table Value1&lt;BR /&gt;
above search give result : 40&lt;/P&gt;

&lt;P&gt;host="host2" | where Value2&amp;lt;40&lt;BR /&gt;
above search gives a list of events&lt;/P&gt;

&lt;P&gt;But when I use above two in one search query like:&lt;BR /&gt;
host="host2" | where Value2&amp;gt;[host="host1" | table Value1]&lt;/P&gt;

&lt;P&gt;it's giving error : Error in 'where' command: Typechecking failed. The '&amp;lt;' operator received different types.&lt;/P&gt;

&lt;P&gt;Kindly help!&lt;/P&gt;</description>
      <pubDate>Wed, 18 Apr 2018 20:53:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Where-with-subsearch/m-p/349325#M103428</guid>
      <dc:creator>nkankur</dc:creator>
      <dc:date>2018-04-18T20:53:51Z</dc:date>
    </item>
    <item>
      <title>Re: Where with subsearch</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Where-with-subsearch/m-p/349326#M103429</link>
      <description>&lt;P&gt;The subsearch is returning field name as well, hence it fails (your where clause becomes &lt;CODE&gt;| where Value2&amp;gt;Value=40&lt;/CODE&gt;). Try any of below&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;host="host2" | where Value2&amp;gt;[host="host1" | table Value1 | return $Value1]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;OR &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;host="host2" | where Value2&amp;gt;[host="host1" | table Value1 | rename Value1 as search]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 18 Apr 2018 21:03:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Where-with-subsearch/m-p/349326#M103429</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2018-04-18T21:03:28Z</dc:date>
    </item>
    <item>
      <title>Re: Where with subsearch</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Where-with-subsearch/m-p/349327#M103430</link>
      <description>&lt;P&gt;Thanks a lot! It worked!&lt;/P&gt;</description>
      <pubDate>Wed, 18 Apr 2018 21:17:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Where-with-subsearch/m-p/349327#M103430</guid>
      <dc:creator>nkankur</dc:creator>
      <dc:date>2018-04-18T21:17:09Z</dc:date>
    </item>
  </channel>
</rss>

