<?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: Help on basic question concerning lookup command in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533838#M150863</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Please can you explain better what you mean with type 1 or type 2?&lt;/P&gt;&lt;P&gt;anyway you can try to modify the lookup or use a subsearch to modify the output.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 22 Dec 2020 14:26:51 GMT</pubDate>
    <dc:creator>aasabatini</dc:creator>
    <dc:date>2020-12-22T14:26:51Z</dc:date>
    <item>
      <title>Help on basic question concerning lookup command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533830#M150859</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;I have a stranfge behavior concerning the search below&lt;/P&gt;&lt;P&gt;In the "host_allIND.csv" file, I have just HOSTNAME from a specific type which is "Type 1"&lt;/P&gt;&lt;P&gt;But when I run the search below, I have also HOSTNAME with type = "Type 2"&lt;/P&gt;&lt;P&gt;How is it possible to have events with HOSTNAME= Type 2 even if in "host_allIND.csv" lookup I have only HOSTNAME=Type 1?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;`boot` 
| fields host BootTime 
| lookup host_allIND.csv HOSTNAME as host output SITE DEPARTMENT CATEGORY 
| stats max(BootTime) as "Boot time" last(SITE) as SITE last(CATEGORY) as CATEGORY last(DEPARTMENT) as DEPARTMENT by host&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 22 Dec 2020 14:12:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533830#M150859</guid>
      <dc:creator>jip31</dc:creator>
      <dc:date>2020-12-22T14:12:56Z</dc:date>
    </item>
    <item>
      <title>Re: Help on basic question concerning lookup command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533838#M150863</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Please can you explain better what you mean with type 1 or type 2?&lt;/P&gt;&lt;P&gt;anyway you can try to modify the lookup or use a subsearch to modify the output.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Dec 2020 14:26:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533838#M150863</guid>
      <dc:creator>aasabatini</dc:creator>
      <dc:date>2020-12-22T14:26:51Z</dc:date>
    </item>
    <item>
      <title>Re: Help on basic question concerning lookup command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533839#M150864</link>
      <description>&lt;P&gt;We don't know what the &lt;FONT face="courier new,courier"&gt;boot&lt;/FONT&gt; macro does, but nothing else in the query limits the results to a particular host.&amp;nbsp; The &lt;FONT face="courier new,courier"&gt;lookup&lt;/FONT&gt; command adds three fields, but does not filter the results.&amp;nbsp; If "Type 2" is not in the lookup file then the SITE, DEPARTMENT, and CATEGORY fields will be null.&lt;/P&gt;&lt;P&gt;To filter out the "Type 1" hosts, use a &lt;FONT face="courier new,courier"&gt;where&lt;/FONT&gt; command or put the desired host into the base query.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;`boot` host="Type 2"
| fields host BootTime 
| lookup host_allIND.csv HOSTNAME as host output SITE DEPARTMENT CATEGORY 
| stats max(BootTime) as "Boot time" last(SITE) as SITE last(CATEGORY) as CATEGORY last(DEPARTMENT) as DEPARTMENT by host&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Dec 2020 14:27:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533839#M150864</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2020-12-22T14:27:22Z</dc:date>
    </item>
    <item>
      <title>Re: Help on basic question concerning lookup command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533848#M150869</link>
      <description>&lt;P&gt;thanks but&amp;nbsp; I thought that in so far as I stats my events with "by host", it just reuses the host existing in my CSV file.....&lt;/P&gt;</description>
      <pubDate>Tue, 22 Dec 2020 14:46:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-on-basic-question-concerning-lookup-command/m-p/533848#M150869</guid>
      <dc:creator>jip31</dc:creator>
      <dc:date>2020-12-22T14:46:47Z</dc:date>
    </item>
  </channel>
</rss>

