<?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 use append to work like Inner join in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743359#M241081</link>
    <description>&lt;P&gt;If all you want is to remove those extra messageID's, you can simply remove those with null request_time, like&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| search request_time = *&lt;/LI-CODE&gt;</description>
    <pubDate>Thu, 03 Apr 2025 05:56:48 GMT</pubDate>
    <dc:creator>yuanliu</dc:creator>
    <dc:date>2025-04-03T05:56:48Z</dc:date>
    <item>
      <title>How to use append to work like Inner join</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743345#M241078</link>
      <description>&lt;P&gt;I have two searches&amp;nbsp; and I only want to find rows which has common MessageID . Currently it is returning extra row because of second search .&amp;nbsp;&lt;/P&gt;&lt;P&gt;Query before Or is returning 100 records&amp;nbsp; and after OR one was returning 110 rows&amp;nbsp; and for those extra 10 rows messageID in first is NULL , So I want to drop those messages . Please help how can i&amp;nbsp; change this query to make it work . I am trying to find count of matched IDs and&amp;nbsp; list of all such ids&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;```query for apigateway call```
(index=aws_np earliest="03/28/2025:13:30:00" latest="03/28/2025:14:35:00" Method response body after transformations: sourcetype="aws:apigateway" business_unit=XX aws_account_alias
="XXXX" network_environment=xxXXX source="API-Gateway-Execution-Logs*" (application="xXXXXX" OR application="xXXXX-xXX") 
| rex field=_raw "Method response body after transformations: (?&amp;lt;json&amp;gt;[^$]+)" 
| spath input=json path="header.messageID" output=messageID 
| spath input=json path="payload.statusType.code" output=status 
| spath input=json path="payload.statusType.text" output=text 
|  spath input=json path="header.action" output=action 
| where status=200  and action="Create" `
| rename _time as request_time 
| table messageID, request_time) 
| append 
```query for 2nd query call```
    [ search kubernetes_cluster="eks-XXX*" index="aws_XXX" sourcetype = "kubernetes_logs" source = *XXXX*  "sendData" 
    | rex field=_raw "sendData: (?&amp;lt;json&amp;gt;[^$]+)" 
    | spath input=json path="header.messageID" output=messageID 
    | rename _time as pubsub_time 
    | table messageID, pubsub_time
 ] |  stats values(request_time) as request_time  values(pubsub_time) as pubsub_time  by messageID &lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Apr 2025 02:48:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743345#M241078</guid>
      <dc:creator>Punnu</dc:creator>
      <dc:date>2025-04-03T02:48:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to use append to work like Inner join</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743359#M241081</link>
      <description>&lt;P&gt;If all you want is to remove those extra messageID's, you can simply remove those with null request_time, like&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| search request_time = *&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 03 Apr 2025 05:56:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743359#M241081</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2025-04-03T05:56:48Z</dc:date>
    </item>
    <item>
      <title>Re: How to use append to work like Inner join</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743362#M241082</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/308511"&gt;@Punnu&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To achieve an inner join effect and only keep results where messageID exists in both searches, you can filter the results &lt;EM&gt;after&lt;/EM&gt; your stats command to remove rows where request_time is null (meaning the messageID only existed in the second search).&lt;/P&gt;&lt;P&gt;&amp;nbsp;Add | where isnotnull(request_time) after your stats command.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;P&gt;&lt;span class="lia-unicode-emoji" title=":glowing_star:"&gt;🌟&lt;/span&gt; &lt;STRONG&gt;Did this answer help you?&lt;/STRONG&gt; If so, please consider:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Adding kudos to show it was useful&lt;/LI&gt;&lt;LI&gt;Marking it as the solution if it resolved your issue&lt;/LI&gt;&lt;LI&gt;Commenting if you need any clarification&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Your feedback encourages the volunteers in this community to continue contributing&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 03 Apr 2025 06:28:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743362#M241082</guid>
      <dc:creator>livehybrid</dc:creator>
      <dc:date>2025-04-03T06:28:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to use append to work like Inner join</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743382#M241083</link>
      <description>&lt;P&gt;hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/170906"&gt;@livehybrid&lt;/a&gt;&amp;nbsp; Thank you for reply . I would like to ask one more question . Post filtering&amp;nbsp; out records how we can find count of messageID&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Apr 2025 10:35:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743382#M241083</guid>
      <dc:creator>Punnu</dc:creator>
      <dc:date>2025-04-03T10:35:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to use append to work like Inner join</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743397#M241084</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/308511"&gt;@Punnu&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you wanted a count of the unique messageID after filtering then a simple stats count should do, as we've already stats by messageID&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| stats count &lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-unicode-emoji" title=":glowing_star:"&gt;🌟&lt;/span&gt; &lt;STRONG&gt;Did this answer help you? If so, please consider&lt;/STRONG&gt;:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Adding kudos to show it was useful&lt;/LI&gt;&lt;LI&gt;Marking it as the solution if it resolved your issue&lt;/LI&gt;&lt;LI&gt;Commenting if you need any clarification&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Your feedback encourages the volunteers in this community to continue contributing.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Apr 2025 13:36:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743397#M241084</guid>
      <dc:creator>livehybrid</dc:creator>
      <dc:date>2025-04-03T13:36:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to use append to work like Inner join</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743404#M241085</link>
      <description>Old post how you could emulate joins in splunk &lt;A href="https://community.splunk.com/t5/Splunk-Search/What-is-the-relation-between-the-Splunk-inner-left-join-and-the/m-p/391288/thread-id/113948" target="_blank"&gt;https://community.splunk.com/t5/Splunk-Search/What-is-the-relation-between-the-Splunk-inner-left-join-and-the/m-p/391288/thread-id/113948&lt;/A&gt;</description>
      <pubDate>Thu, 03 Apr 2025 14:41:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-append-to-work-like-Inner-join/m-p/743404#M241085</guid>
      <dc:creator>isoutamo</dc:creator>
      <dc:date>2025-04-03T14:41:21Z</dc:date>
    </item>
  </channel>
</rss>

