<?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 the second index to search missing fields in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602304#M209645</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/241755"&gt;@NewGhost&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;to correlate events from different indexes you need a correlation key, is there a field (eventually with different name) to use for correlation.&lt;/P&gt;&lt;P&gt;e.g. in your searches:&amp;nbsp;&lt;SPAN&gt;ComputerName from search1 and&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;MachineDn from search2 have the same values?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Then, in the first search, if you use _time as key in stats command, it's better to use bin command before, otherwise you'll have too many results.&lt;/P&gt;&lt;P&gt;About join, I use it only when there isn't any other solution becasue it's a very slow command, but anyway, it still need a correlation key, otherwise it isn't possible to correlate events.&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
    <pubDate>Sat, 18 Jun 2022 06:00:40 GMT</pubDate>
    <dc:creator>gcusello</dc:creator>
    <dc:date>2022-06-18T06:00:40Z</dc:date>
    <item>
      <title>How to use the second index to search missing fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602278#M209638</link>
      <description>&lt;P&gt;Please see this search - i'm trying to add missing field values from another index to this search.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;index=1 earliest=-9d latest=now ExternalApiType=Event_DetectionSummaryEvent&lt;/P&gt;&lt;P&gt;| fillnull&lt;/P&gt;&lt;P&gt;| stats values(ComputerName) AS ComputerName values(DetectName) AS DetectName values(UserName) AS User values(event_platform) AS Platform values(FileVersion) AS SensorVersion P values(MachineDn) AS OU values(SiteName) AS SiteName count(_time) AS count BY _time EventUUID&lt;/P&gt;&lt;P&gt;| sort 0 - _time&lt;/P&gt;&lt;P&gt;| eval Time=strftime(_time, "%m/%d/%Y %H:%M:%S")&lt;/P&gt;&lt;P&gt;| appendcols&lt;/P&gt;&lt;P&gt;[ search earliest=-9d latest=now index=json "AuditKeyValues{}.Key"=new_state "AuditKeyValues{}.ValueString"=*&lt;/P&gt;&lt;P&gt;| spath&lt;/P&gt;&lt;P&gt;| spath AuditKeyValue{}&lt;BR /&gt;]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Index=1 has fields&amp;nbsp;ComputerName,&amp;nbsp;DetectName,&amp;nbsp;UserName, _time, EventUUID&lt;/P&gt;&lt;P&gt;index=main has fields&amp;nbsp;event_platform,&amp;nbsp;FileVersion,&amp;nbsp;MachineDn, SiteName&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to pull the fields from index=main into the stats command of the index=1. I thought&amp;nbsp; it's as simple as adding the index=main at the beginning of the search with an OR:&lt;/P&gt;&lt;P&gt;(index=json ExternalApiType=Event_DetectionSummaryEvent) OR (index=main FileVersion=*).&lt;/P&gt;&lt;P&gt;But it's not working. I have to have the ExternalApiType value and it's only in the first index. I also tried join with the subsearch, but it didn't work. The original search is for 90 days, so I shouldn't use a subsearch anyways.&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2022 18:19:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602278#M209638</guid>
      <dc:creator>NewGhost</dc:creator>
      <dc:date>2022-06-17T18:19:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to use the second index to search missing fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602304#M209645</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/241755"&gt;@NewGhost&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;to correlate events from different indexes you need a correlation key, is there a field (eventually with different name) to use for correlation.&lt;/P&gt;&lt;P&gt;e.g. in your searches:&amp;nbsp;&lt;SPAN&gt;ComputerName from search1 and&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;MachineDn from search2 have the same values?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Then, in the first search, if you use _time as key in stats command, it's better to use bin command before, otherwise you'll have too many results.&lt;/P&gt;&lt;P&gt;About join, I use it only when there isn't any other solution becasue it's a very slow command, but anyway, it still need a correlation key, otherwise it isn't possible to correlate events.&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Sat, 18 Jun 2022 06:00:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602304#M209645</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-06-18T06:00:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to use the second index to search missing fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602412#M209683</link>
      <description>&lt;P&gt;They both have ComputerName field. I'll try using the bin too, thanks. My ultimate goal is to have the number of detections for ComputerNames over time, so I'll probably have to use the timechart, but I'm not even there yet. This was just me starting to combine all the information together.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jun 2022 12:32:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602412#M209683</guid>
      <dc:creator>NewGhost</dc:creator>
      <dc:date>2022-06-20T12:32:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to use the second index to search missing fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602424#M209689</link>
      <description>&lt;P&gt;I realize my question is too confusing and I probably need to test my queries some more. I just tried to understand how to do the join correctly, and I think if I only want certain fields to show in the end I just put |table at the end.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jun 2022 14:44:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602424#M209689</guid>
      <dc:creator>NewGhost</dc:creator>
      <dc:date>2022-06-20T14:44:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to use the second index to search missing fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602425#M209690</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/241755"&gt;@NewGhost&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;good for you, see next time!&lt;/P&gt;&lt;P&gt;Ciao and happy splunking&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;&lt;P&gt;P.S.: Karma Points are appreciated &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jun 2022 14:55:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-the-second-index-to-search-missing-fields/m-p/602425#M209690</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-06-20T14:55:12Z</dc:date>
    </item>
  </channel>
</rss>

