<?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 lookup query in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464603#M191612</link>
    <description>&lt;P&gt;Greetings!!&lt;/P&gt;

&lt;P&gt;I have created a new lookup table xyz.csv that contain host and hostname(as description) and the name of lookup is xyz_lookup&lt;/P&gt;

&lt;P&gt;when i search |inputlookup xyz_lookup  I got the table with host and hostname,&lt;/P&gt;

&lt;P&gt;BUT my question is: &lt;BR /&gt;
what query can I use to combine the other command with this lookup,&lt;/P&gt;

&lt;P&gt;when I search for index= xx  sourcetype=ttt |top host    -this gives me host,count,percent BUT i want also to use that it gives me also hostname , not only host ...&lt;/P&gt;

&lt;P&gt;Help me on how I could combine my lookup with other query? Thank you in advance&lt;/P&gt;

&lt;P&gt;regards&lt;BR /&gt;
paci N&lt;/P&gt;</description>
    <pubDate>Wed, 11 Dec 2019 10:18:16 GMT</pubDate>
    <dc:creator>pacifikn</dc:creator>
    <dc:date>2019-12-11T10:18:16Z</dc:date>
    <item>
      <title>lookup query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464603#M191612</link>
      <description>&lt;P&gt;Greetings!!&lt;/P&gt;

&lt;P&gt;I have created a new lookup table xyz.csv that contain host and hostname(as description) and the name of lookup is xyz_lookup&lt;/P&gt;

&lt;P&gt;when i search |inputlookup xyz_lookup  I got the table with host and hostname,&lt;/P&gt;

&lt;P&gt;BUT my question is: &lt;BR /&gt;
what query can I use to combine the other command with this lookup,&lt;/P&gt;

&lt;P&gt;when I search for index= xx  sourcetype=ttt |top host    -this gives me host,count,percent BUT i want also to use that it gives me also hostname , not only host ...&lt;/P&gt;

&lt;P&gt;Help me on how I could combine my lookup with other query? Thank you in advance&lt;/P&gt;

&lt;P&gt;regards&lt;BR /&gt;
paci N&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2019 10:18:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464603#M191612</guid>
      <dc:creator>pacifikn</dc:creator>
      <dc:date>2019-12-11T10:18:16Z</dc:date>
    </item>
    <item>
      <title>Re: lookup query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464604#M191613</link>
      <description>&lt;P&gt;Hello!&lt;/P&gt;

&lt;P&gt;You can try to output your inputlookup results (since inputlookup should be the first item in your search) with the MAP command to combine results.&lt;/P&gt;

&lt;P&gt;You can find more info about this in the following posts:&lt;/P&gt;

&lt;P&gt;&lt;A href="https://docs.splunk.com/Documentation/SplunkCloud/8.0.0/SearchReference/Map"&gt;https://docs.splunk.com/Documentation/SplunkCloud/8.0.0/SearchReference/Map&lt;/A&gt;&lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/743935/problem-with-map-command-using-search-from-lookup.html"&gt;https://answers.splunk.com/answers/743935/problem-with-map-command-using-search-from-lookup.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2019 10:36:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464604#M191613</guid>
      <dc:creator>raduurjan</dc:creator>
      <dc:date>2019-12-11T10:36:56Z</dc:date>
    </item>
    <item>
      <title>Re: lookup query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464605#M191614</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;index= xx sourcetype=ttt 
|top host
|lookup xyz_lookup 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Hi, @pacifikn&lt;BR /&gt;
how is it?&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2019 11:48:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464605#M191614</guid>
      <dc:creator>to4kawa</dc:creator>
      <dc:date>2019-12-11T11:48:53Z</dc:date>
    </item>
    <item>
      <title>Re: lookup query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464606#M191615</link>
      <description>&lt;P&gt;Thank you All for your quick response,&lt;/P&gt;

&lt;P&gt;I didn't tell soon , I have tried to use OUTPUTNEW and it is working correctly,&lt;/P&gt;

&lt;P&gt;index=xxx sourrcetype=tttt action=T |top host  |lookup name_lookup host OUTPUTNEW hostname&lt;/P&gt;

&lt;P&gt;I used the above command and it was working correctly.&lt;/P&gt;

&lt;P&gt;Thank you again for the other way you mentioned above it is also working good! thank you all&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2019 06:27:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464606#M191615</guid>
      <dc:creator>pacifikn</dc:creator>
      <dc:date>2019-12-12T06:27:00Z</dc:date>
    </item>
    <item>
      <title>Re: lookup query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464607#M191616</link>
      <description>&lt;P&gt;Dear to4kawa , &lt;/P&gt;

&lt;P&gt;now it is working good , but when I saw the command you wrote, it looks the same with the one I used but I added the name of the firstColumn OUTPUTNEW  secondColumn(description of the first column)&lt;/P&gt;

&lt;P&gt;like this:&lt;BR /&gt;
 index= xx sourcetype=ttt &lt;BR /&gt;
 |top host&lt;BR /&gt;
 |lookup xyz_lookup host OUTPUTNEW hostname(Desc)&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2019 06:47:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/lookup-query/m-p/464607#M191616</guid>
      <dc:creator>pacifikn</dc:creator>
      <dc:date>2019-12-12T06:47:42Z</dc:date>
    </item>
  </channel>
</rss>

