<?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 Merging result of inputlookup file with subsearch to get required results in Splunk Enterprise Security</title>
    <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379207#M3820</link>
    <description>&lt;P&gt;i have one csv file which contains device name location data , i need to get count of all the device name location wise.&lt;BR /&gt;
and then  i am trying to get malware count and spyware count on the infected machines for one of indexed data as below but this search is not working  "" Error in 'stats' command: The argument 'index=abc' is invalid"" if  i remove inputlookup first line i will get results but i wont get total no of computers . how should i merge these two requirement . &lt;/P&gt;

&lt;P&gt;|inputlookup xyz.csv  | stats count("Device Name") as Total_Computers by Location&lt;BR /&gt;
index=abc  | search TMCM:SLF_INCIDENT&lt;BR /&gt;
|lookup xyz.csv "Device Name" as nodename OUTPUT Location&lt;BR /&gt;
| stats count(nodename) as InfectedComputers  count(signature) as MalwareCount &lt;BR /&gt;
count(Spyware) as Spywarecount  by Location&lt;BR /&gt;
 | table Total_Computers,Location,InfectedComputers, MalwareCount, Spywarecount &lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 21:17:32 GMT</pubDate>
    <dc:creator>SunilMaharishi</dc:creator>
    <dc:date>2020-09-29T21:17:32Z</dc:date>
    <item>
      <title>Merging result of inputlookup file with subsearch to get required results</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379207#M3820</link>
      <description>&lt;P&gt;i have one csv file which contains device name location data , i need to get count of all the device name location wise.&lt;BR /&gt;
and then  i am trying to get malware count and spyware count on the infected machines for one of indexed data as below but this search is not working  "" Error in 'stats' command: The argument 'index=abc' is invalid"" if  i remove inputlookup first line i will get results but i wont get total no of computers . how should i merge these two requirement . &lt;/P&gt;

&lt;P&gt;|inputlookup xyz.csv  | stats count("Device Name") as Total_Computers by Location&lt;BR /&gt;
index=abc  | search TMCM:SLF_INCIDENT&lt;BR /&gt;
|lookup xyz.csv "Device Name" as nodename OUTPUT Location&lt;BR /&gt;
| stats count(nodename) as InfectedComputers  count(signature) as MalwareCount &lt;BR /&gt;
count(Spyware) as Spywarecount  by Location&lt;BR /&gt;
 | table Total_Computers,Location,InfectedComputers, MalwareCount, Spywarecount &lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 21:17:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379207#M3820</guid>
      <dc:creator>SunilMaharishi</dc:creator>
      <dc:date>2020-09-29T21:17:32Z</dc:date>
    </item>
    <item>
      <title>Re: Merging result of inputlookup file with subsearch to get required results</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379208#M3821</link>
      <description>&lt;P&gt;hi @SunilMaharishi &lt;BR /&gt;
try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;|inputlookup xyz.csv | stats count("Device Name") as Total_Computers by Location|appendcols [search index=abc | search TMCM:SLF_INCIDENT
|lookup xyz.csv "Device Name" as nodename OUTPUT Location
| stats count(nodename) as InfectedComputers count(signature) as MalwareCount 
count(Spyware) as Spywarecount by Location ]
| table Total_Computers,Location,InfectedComputers, MalwareCount, Spywarecount 
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 20 Sep 2018 12:07:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379208#M3821</guid>
      <dc:creator>harishalipaka</dc:creator>
      <dc:date>2018-09-20T12:07:48Z</dc:date>
    </item>
    <item>
      <title>Re: Merging result of inputlookup file with subsearch to get required results</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379209#M3822</link>
      <description>&lt;P&gt;i tried using this , however i am getting the total computers and location but" InfectedComputers, MalwareCount, Spywarecount  " is blank and not having any values&lt;/P&gt;</description>
      <pubDate>Thu, 20 Sep 2018 13:25:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379209#M3822</guid>
      <dc:creator>SunilMaharishi</dc:creator>
      <dc:date>2018-09-20T13:25:04Z</dc:date>
    </item>
    <item>
      <title>Re: Merging result of inputlookup file with subsearch to get required results</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379210#M3823</link>
      <description>&lt;P&gt;i tried using append command and that is giving correct result , little bit modified the search though&lt;/P&gt;</description>
      <pubDate>Thu, 20 Sep 2018 13:25:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Merging-result-of-inputlookup-file-with-subsearch-to-get/m-p/379210#M3823</guid>
      <dc:creator>SunilMaharishi</dc:creator>
      <dc:date>2018-09-20T13:25:37Z</dc:date>
    </item>
  </channel>
</rss>

