<?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: need help with joining two queries in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450784#M171346</link>
    <description>&lt;P&gt;Hi @MuS&lt;/P&gt;

&lt;P&gt;Thanks for the response. &lt;/P&gt;

&lt;P&gt;It's not working unfortunately. &lt;/P&gt;

&lt;P&gt;Let me tell the clear requirement here... I need the SOR,  Filename,  expected_time values when there is no arrival time.  Can you please suggest me the alternative way&lt;/P&gt;

&lt;P&gt;Unfortunately I m not able copy my query here. &lt;/P&gt;</description>
    <pubDate>Fri, 10 May 2019 07:10:50 GMT</pubDate>
    <dc:creator>pench2k19</dc:creator>
    <dc:date>2019-05-10T07:10:50Z</dc:date>
    <item>
      <title>need help with joining two queries</title>
      <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450779#M171341</link>
      <description>&lt;P&gt;Hi ninjas,&lt;/P&gt;

&lt;P&gt;i have two queries with ] the output as follows&lt;/P&gt;

&lt;P&gt;query1 output fields:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;SOR&lt;/STRONG&gt;        &lt;STRONG&gt;filename&lt;/STRONG&gt;     &lt;STRONG&gt;expected_time&lt;/STRONG&gt; &lt;BR /&gt;
1ci                       extract              12:30:00  10-5-2019&lt;/P&gt;

&lt;P&gt;query2 output fields:&lt;BR /&gt;
&lt;STRONG&gt;SOR&lt;/STRONG&gt;        ** filename**         &lt;STRONG&gt;real_time&lt;/STRONG&gt;&lt;BR /&gt;
1art                    congig                    01:30:00 10-5-2019&lt;/P&gt;

&lt;P&gt;The second query values are subset of  first query.&lt;/P&gt;

&lt;P&gt;Now i want to print the values  of SOR , filename and expected_time when there is no real_time value in the second query.&lt;/P&gt;

&lt;P&gt;can you please help here.&lt;/P&gt;

&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/199197"&gt;@jkat54&lt;/a&gt; &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/156785"&gt;@vnravikumar&lt;/a&gt; &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/15147"&gt;@somesoni2&lt;/a&gt; &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/1406"&gt;@woodcock&lt;/a&gt; &lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 00:27:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450779#M171341</guid>
      <dc:creator>pench2k19</dc:creator>
      <dc:date>2020-09-30T00:27:55Z</dc:date>
    </item>
    <item>
      <title>Re: need help with joining two queries</title>
      <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450780#M171342</link>
      <description>&lt;P&gt;I'm not clear on your query, if you need a lookup or join or transaction between the queries&lt;/P&gt;

&lt;P&gt;Just a guess, Is this what you are expecting? The below should print  fields irrespective of  and if SOR is both the same, it will print the join&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;query1&amp;gt; 
| join type=left SOR [|&amp;lt;query2&amp;gt;]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 10 May 2019 06:22:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450780#M171342</guid>
      <dc:creator>koshyk</dc:creator>
      <dc:date>2019-05-10T06:22:23Z</dc:date>
    </item>
    <item>
      <title>Re: need help with joining two queries</title>
      <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450781#M171343</link>
      <description>&lt;P&gt;Hi pench2k19,&lt;/P&gt;

&lt;P&gt;best option is to forget about &lt;CODE&gt;join&lt;/CODE&gt; completely for reasons. &lt;/P&gt;

&lt;P&gt;Just use a plain &lt;CODE&gt;stats&lt;/CODE&gt; instead:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; query1 OR query2 | stats values(*) AS * by SOR
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;this works best, and you will not hit any hidden limits &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;Learn more over here &lt;A href="https://answers.splunk.com/answers/129424/how-to-compare-fields-over-multiple-sourcetypes-without-join-append-or-use-of-subsearches.html"&gt;https://answers.splunk.com/answers/129424/how-to-compare-fields-over-multiple-sourcetypes-without-join-append-or-use-of-subsearches.html&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;cheers, MuS&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 06:33:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450781#M171343</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2019-05-10T06:33:39Z</dc:date>
    </item>
    <item>
      <title>Re: need help with joining two queries</title>
      <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450782#M171344</link>
      <description>&lt;P&gt;Hi @MuS&lt;/P&gt;

&lt;P&gt;Thanks for the reply. &lt;/P&gt;

&lt;P&gt;Unfortunately your solution is not working in my case. &lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 07:08:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450782#M171344</guid>
      <dc:creator>pench2k19</dc:creator>
      <dc:date>2019-05-10T07:08:23Z</dc:date>
    </item>
    <item>
      <title>Re: need help with joining two queries</title>
      <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450783#M171345</link>
      <description>&lt;P&gt;I'm pretty sure it would if you could provide more context, and some sample events &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt; &lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 07:09:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450783#M171345</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2019-05-10T07:09:40Z</dc:date>
    </item>
    <item>
      <title>Re: need help with joining two queries</title>
      <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450784#M171346</link>
      <description>&lt;P&gt;Hi @MuS&lt;/P&gt;

&lt;P&gt;Thanks for the response. &lt;/P&gt;

&lt;P&gt;It's not working unfortunately. &lt;/P&gt;

&lt;P&gt;Let me tell the clear requirement here... I need the SOR,  Filename,  expected_time values when there is no arrival time.  Can you please suggest me the alternative way&lt;/P&gt;

&lt;P&gt;Unfortunately I m not able copy my query here. &lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 07:10:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450784#M171346</guid>
      <dc:creator>pench2k19</dc:creator>
      <dc:date>2019-05-10T07:10:50Z</dc:date>
    </item>
    <item>
      <title>Re: need help with joining two queries</title>
      <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450785#M171347</link>
      <description>&lt;P&gt;To give you more context,  in the first query I have loopkup file as data source and in the second query I mean using real time logs. &lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 07:13:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450785#M171347</guid>
      <dc:creator>pench2k19</dc:creator>
      <dc:date>2019-05-10T07:13:59Z</dc:date>
    </item>
    <item>
      <title>Re: need help with joining two queries</title>
      <link>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450786#M171348</link>
      <description>&lt;P&gt;I cannot help unless you show us the 2 searches (the SPL).&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 13:41:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/need-help-with-joining-two-queries/m-p/450786#M171348</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-05-10T13:41:26Z</dc:date>
    </item>
  </channel>
</rss>

