<?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 Need help with Splunk query to merge subsearch with main search in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Need-help-with-Splunk-query-to-merge-subsearch-with-main-search/m-p/530224#M149814</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am trying to craft a query that will look for Windows devices that have been rebooted and then have accessed a certain file path to launch a service. I have attempted this by creating a subsearch for the windows eventid 6005 (reboot), and then passing the computer name associated with that event to the main search for devices that have accessed a filepath. I am not sure how to obtain an output that will show the computer name of a device that has recently had a reboot and also has accessed the file path.&lt;/P&gt;&lt;P&gt;Thank you for any help, I am new to Splunk subsearches and appreciate any pointers.&lt;/P&gt;&lt;P&gt;index=wineventlog Creator_Process_Name="C:\\Program Files\\XXX\\YYY\\file.exe"&lt;BR /&gt;[search index=wineventlog&amp;nbsp; ComputerName="*xyz.local"&amp;nbsp; EventCode="6005" | stats count by ComputerName, EventCode | fields ComputerName, EventCode]&lt;BR /&gt;|stats values (?) by EventCode&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 20 Nov 2020 14:45:00 GMT</pubDate>
    <dc:creator>Anon4Now</dc:creator>
    <dc:date>2020-11-20T14:45:00Z</dc:date>
    <item>
      <title>Need help with Splunk query to merge subsearch with main search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-help-with-Splunk-query-to-merge-subsearch-with-main-search/m-p/530224#M149814</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am trying to craft a query that will look for Windows devices that have been rebooted and then have accessed a certain file path to launch a service. I have attempted this by creating a subsearch for the windows eventid 6005 (reboot), and then passing the computer name associated with that event to the main search for devices that have accessed a filepath. I am not sure how to obtain an output that will show the computer name of a device that has recently had a reboot and also has accessed the file path.&lt;/P&gt;&lt;P&gt;Thank you for any help, I am new to Splunk subsearches and appreciate any pointers.&lt;/P&gt;&lt;P&gt;index=wineventlog Creator_Process_Name="C:\\Program Files\\XXX\\YYY\\file.exe"&lt;BR /&gt;[search index=wineventlog&amp;nbsp; ComputerName="*xyz.local"&amp;nbsp; EventCode="6005" | stats count by ComputerName, EventCode | fields ComputerName, EventCode]&lt;BR /&gt;|stats values (?) by EventCode&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 20 Nov 2020 14:45:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-help-with-Splunk-query-to-merge-subsearch-with-main-search/m-p/530224#M149814</guid>
      <dc:creator>Anon4Now</dc:creator>
      <dc:date>2020-11-20T14:45:00Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with Splunk query to merge subsearch with main search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-help-with-Splunk-query-to-merge-subsearch-with-main-search/m-p/530238#M149817</link>
      <description>&lt;P&gt;Try something like this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=wineventlog ComputerName="*xyz.local" (EventCode="6005" OR Creator_Process_Name="C:\\Program Files\\XXX\\YYY\\file.exe")
|stats values(*) as * by ComputerName&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 20 Nov 2020 16:10:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-help-with-Splunk-query-to-merge-subsearch-with-main-search/m-p/530238#M149817</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2020-11-20T16:10:13Z</dc:date>
    </item>
  </channel>
</rss>

