<?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 perform lookup on CSV file from search on index in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644370#M223187</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/254242"&gt;@LearningGuy&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here are some example methods&lt;/P&gt;&lt;P&gt;Only outputs results matched against name field in lookup file&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=testindex name=*
| lookup employee.csv name OUTPUT positon company&lt;/LI-CODE&gt;&lt;P&gt;Outputs all results and tests whether a match in lookup file existed&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=testindex name=*
| inputlookup append=true employee.csv
| fields name address phone position company
| stats values(*) AS * BY name
| eval intestindex=if(isnotnull(company), "yes", "no")&lt;/LI-CODE&gt;&lt;P&gt;Hope that helps&lt;/P&gt;</description>
    <pubDate>Wed, 24 May 2023 01:08:21 GMT</pubDate>
    <dc:creator>yeahnah</dc:creator>
    <dc:date>2023-05-24T01:08:21Z</dc:date>
    <item>
      <title>How to perform lookup on CSV file from search on index?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644368#M223186</link>
      <description>&lt;P&gt;how to perform lookup on CSV file from search on index?&lt;BR /&gt;For example below:&amp;nbsp;&amp;nbsp; I want to find out if&amp;nbsp; "name" on employee.csv exists on "name" on testindex&lt;BR /&gt;With the data below, the result should be name3&amp;nbsp;&amp;nbsp; addr3&amp;nbsp;&amp;nbsp; phone3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Please help. Thank you!!&lt;BR /&gt;index=testindex&amp;nbsp;&amp;nbsp;&amp;nbsp; |&amp;nbsp; inputlookup employee.csv&amp;nbsp;&amp;nbsp; | field name&amp;nbsp;&amp;nbsp; ???&amp;nbsp; ==&amp;gt; does not work&lt;BR /&gt;result:&lt;BR /&gt;&amp;nbsp;name&amp;nbsp;&amp;nbsp;&amp;nbsp; | &amp;nbsp; address |&amp;nbsp; phone&lt;BR /&gt;name1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; addr1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; phone1&lt;BR /&gt;name3 &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; addr3 &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; phone3&lt;/P&gt;
&lt;P&gt;employee.csv&lt;BR /&gt;name &amp;nbsp; |&amp;nbsp; position | company |&amp;nbsp;&lt;BR /&gt;name3&amp;nbsp;&amp;nbsp;&amp;nbsp; position3&amp;nbsp;&amp;nbsp; company3&lt;/P&gt;</description>
      <pubDate>Thu, 25 May 2023 09:36:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644368#M223186</guid>
      <dc:creator>LearningGuy</dc:creator>
      <dc:date>2023-05-25T09:36:24Z</dc:date>
    </item>
    <item>
      <title>Re: how to perform lookup on CSV file from search on index</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644370#M223187</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/254242"&gt;@LearningGuy&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here are some example methods&lt;/P&gt;&lt;P&gt;Only outputs results matched against name field in lookup file&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=testindex name=*
| lookup employee.csv name OUTPUT positon company&lt;/LI-CODE&gt;&lt;P&gt;Outputs all results and tests whether a match in lookup file existed&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=testindex name=*
| inputlookup append=true employee.csv
| fields name address phone position company
| stats values(*) AS * BY name
| eval intestindex=if(isnotnull(company), "yes", "no")&lt;/LI-CODE&gt;&lt;P&gt;Hope that helps&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 01:08:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644370#M223187</guid>
      <dc:creator>yeahnah</dc:creator>
      <dc:date>2023-05-24T01:08:21Z</dc:date>
    </item>
    <item>
      <title>Re: how to perform lookup on CSV file from search on index</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644376#M223189</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;index=testindex name=*&amp;nbsp;&amp;nbsp;| lookup employee.csv name OUTPUT position company&lt;BR /&gt;1)&amp;nbsp; a) Is&amp;nbsp; &amp;nbsp;name=*&amp;nbsp; &amp;nbsp; required as a field that I want to look up?&amp;nbsp;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;b) if I want to lookup name on employee.csv that has name2, should I use | lookup employee.csv name2?&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; c) So if the field that I want to lookup is address, should I use address=*?&lt;BR /&gt;2)&amp;nbsp; I used your query to perform lookup on employee.csv that does not&amp;nbsp; have any match, but it still showed all output on the search result.&amp;nbsp; &amp;nbsp;It also did not show position and company field&lt;BR /&gt;Can you please fix this? Thanks&lt;BR /&gt;&lt;BR /&gt;index=testindex name=*&lt;BR /&gt;| inputlookup append=true employee.csv&lt;BR /&gt;| fields name address phone position company&lt;BR /&gt;| stats values(*) AS * BY name&lt;BR /&gt;| eval intestindex=if(isnotnull(company), "yes", "no")&lt;BR /&gt;&lt;BR /&gt;1) The search worked fine.&amp;nbsp;Can you please explain the logic behind it?&amp;nbsp;&lt;BR /&gt;2) I am not sure the purpose of append=true.&amp;nbsp; &amp;nbsp;Did it append something on csv files?&lt;BR /&gt;3) What is the purpose of:&amp;nbsp; &amp;nbsp; of values (*) AS * BY Name&lt;BR /&gt;4) What is the difference between inputlookup and lookup?&lt;BR /&gt;&lt;BR /&gt;I appreciate your help. Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 02:37:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644376#M223189</guid>
      <dc:creator>LearningGuy</dc:creator>
      <dc:date>2023-05-24T02:37:59Z</dc:date>
    </item>
    <item>
      <title>Re: how to perform lookup on CSV file from search on index</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644385#M223191</link>
      <description>&lt;P&gt;The Splunk docs are a good place to get more acquainted with SPL commands&amp;nbsp;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://docs.splunk.com/Documentation/Splunk/9.0.4/SearchReference/Lookup" target="_blank" rel="noopener"&gt;https://docs.splunk.com/Documentation/Splunk/9.0.4/SearchReference/Lookup&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://docs.splunk.com/Documentation/Splunk/9.0.4/SearchReference/Inputlookup" target="_blank" rel="noopener"&gt;https://docs.splunk.com/Documentation/Splunk/9.0.4/SearchReference/Inputlookup&lt;/A&gt;&lt;/P&gt;&lt;P&gt;1.&amp;nbsp;a) The name=* does a couple of things:&amp;nbsp;it filters events that have name=&amp;lt;value&amp;gt;, and it also tells Splunk query that you are interested in this field so extract it as a key value pair.&amp;nbsp; This may be important depending on the search mode you are using (fast, smart, verbose).&amp;nbsp; &amp;nbsp;And yes, it is a must for the lookup to work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;b) In this case,&amp;nbsp;the event "name" field equates to a lookup csv header "name".&amp;nbsp; &amp;nbsp;If the search had a field called name1 then the lookup syntax is "lookup&amp;nbsp;&lt;SPAN&gt;employee.csv name AS name1"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;c) Yes, though note, altering your base search filters may also alter your result output.&amp;nbsp; Like most scripting languages there are many ways to do things, which have there pros and cons.&amp;nbsp; But generally, if you know you are interested in a field, (or fields), then using them in the base search helps ensure they are auto extracted and ready for subsequent usage.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2. Yeah, my mistake.&amp;nbsp; You can filter for matches like this.&amp;nbsp;&amp;nbsp;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=testindex name=*
| lookup employee.csv name OUTPUT positon company
| search company=*&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If the lookup has a match (and assuming the event does not have a field called company) then event will be enriched with the company field result&lt;BR /&gt;&lt;BR /&gt;For the second query, here are some comments...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=testindex name=*
``` append the whole lookup file to the search results ```
| inputlookup append=true employee.csv
``` output the fields I'm interested in ```
| fields name address phone position company
``` summarise/transform the results into a table using name as the grouping jey``` 
| stats values(*) AS * BY name
``` add a new field with a tested value ```
| eval intestindex=if(isnotnull(company), "yes", "no")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;As you may have noticed, the stats command changes the output so you do not see the _raw events anymore.&lt;BR /&gt;&lt;BR /&gt;Play around with it to keep learning.&amp;nbsp; Remove the bottom line and repeat search to see how each line changes the result set.&lt;BR /&gt;&lt;BR /&gt;If this has answered your question then please mark this as solution provided.&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 23:01:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644385#M223191</guid>
      <dc:creator>yeahnah</dc:creator>
      <dc:date>2023-05-24T23:01:50Z</dc:date>
    </item>
    <item>
      <title>Re: how to perform lookup on CSV file from search on index</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644546#M223225</link>
      <description>&lt;P&gt;Hello,&lt;BR /&gt;I appreciate your help. My apology. It turns out that there are 2 fields that I needed to filter out.&lt;BR /&gt;The lookup solution that you provided worked, but not with 2 column.&lt;BR /&gt;The inputlookup solution that you provided give me &lt;STRONG&gt;all results&lt;/STRONG&gt;, instead of providing a filter.&lt;BR /&gt;My goal is to &lt;STRONG&gt;lookup and filter&lt;/STRONG&gt;, not only lookup.&amp;nbsp; &amp;nbsp; See the scenario below. Please help.&amp;nbsp;Thank you so much&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;ip&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; location&amp;nbsp; &amp;nbsp;(table 1)&amp;nbsp;&lt;/STRONG&gt;&lt;BR /&gt;1.1.1.1&amp;nbsp; &amp;nbsp; NY&lt;BR /&gt;2.2.2.2&amp;nbsp; &amp;nbsp; CA&lt;BR /&gt;3.3.3.3&amp;nbsp; &amp;nbsp;TX&lt;BR /&gt;4.4.4.4&amp;nbsp; &amp;nbsp; GA&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ip1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;|&amp;nbsp; &amp;nbsp;ip2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;| name&amp;nbsp; &amp;nbsp; &amp;nbsp; (table 2)&lt;/STRONG&gt;&lt;BR /&gt;2.2.2.2&amp;nbsp; &amp;nbsp; &amp;nbsp; |&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; | name2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; (ip2 is empty on this row)&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; |&amp;nbsp;4.4.4.4 | name4&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; (ip1 is empty on this row)&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;output:&amp;nbsp; &amp;nbsp;(table 1 lookup and filter based on table 2)&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;ip&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; |&amp;nbsp; &amp;nbsp;ip1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;|&amp;nbsp; &amp;nbsp; ip2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;| location&amp;nbsp; &amp;nbsp;| name&lt;/STRONG&gt;&lt;BR /&gt;2.2.2.2&amp;nbsp; &amp;nbsp; 2.2.2.2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; NY&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;name2&lt;BR /&gt;4.4.4.4&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 4.4.4.4&amp;nbsp; &amp;nbsp; &amp;nbsp;GA&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; name4&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 18:28:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644546#M223225</guid>
      <dc:creator>LearningGuy</dc:creator>
      <dc:date>2023-05-24T18:28:58Z</dc:date>
    </item>
    <item>
      <title>Re: how to perform lookup on CSV file from search on index</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644563#M223228</link>
      <description>&lt;P&gt;The aim was only ever to demonstrate how lookups could be used.&amp;nbsp; Further filtering of results can be done with "search", "where", or the "regex" commands.&lt;BR /&gt;&lt;BR /&gt;I'm unclear with the problem you have outlined as you have presented it all as tables.&amp;nbsp; &amp;nbsp;What is the lookup and what are the raw events.&amp;nbsp; Maybe present the SPL you already have with examples of the raw events.&lt;BR /&gt;&lt;BR /&gt;If you want to have the lookup match (table 1?) on the raw events (table2?) then you just need to do two lookups.&amp;nbsp; Here's a run anywhere example&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| makeresults| eval _raw="ip,location
1.1.1.1,NY
2.2.2.2,CA
3.3.3.3,TX
4.4.4.4,GA"
| multikv forceheader=1 | table ip location | outputlookup mytemplookup.csv  ``` 1. create a lookup file (table1)```
``` 2. create some dummy events (table2)```
| streamstats count
| eval ip1=if(count=2, ip, null())
      ,ip2=if(count=4, ip, null())
      ,name=case(count=2, "name2", count=4, "name4")
| table ip1 ip2 name
``` 3. the following uses the lookup and filters results ```
| lookup mytemplookup.csv ip AS ip1 OUTPUT ip location
| lookup mytemplookup.csv ip AS ip2 OUTPUT ip location
| search ip1=* OR ip2=*
| table ip* location name&lt;/LI-CODE&gt;&lt;P&gt;The first two parts simply create some dummy data to demonstrate (an example) how&amp;nbsp; you would use the SPL in the third part of the query to produce your output.&amp;nbsp; Obviously, you'll need to alter this to work with what you have got so far.&amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Hopefully that makes sense&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 23:36:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644563#M223228</guid>
      <dc:creator>yeahnah</dc:creator>
      <dc:date>2023-05-24T23:36:53Z</dc:date>
    </item>
    <item>
      <title>Re: how to perform lookup on CSV file from search on index</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644631#M223241</link>
      <description>&lt;P&gt;Hello,&lt;BR /&gt;Sorry I wasn't clear.&amp;nbsp; Table 1 is from raw event (syslog), let say index=table1.&amp;nbsp; The content is not only 4 rows, it's more than 100k in 24 hour.&amp;nbsp; &amp;nbsp;I am trying to filter out that 100k ip addresses in table1 events&amp;nbsp; from ip addresses listed in CSV (i called it table2 that has 2 column IP address1,&amp;nbsp; ip address2)&lt;BR /&gt;Your initial lookup solution worked but only for 1 column (ipaddress_1).&lt;BR /&gt;If I do this manually, I would put the data in excel and perform a VLOOKUP and filter out the row&amp;nbsp;&lt;BR /&gt;Thank you!!&lt;/P&gt;</description>
      <pubDate>Thu, 25 May 2023 13:25:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644631#M223241</guid>
      <dc:creator>LearningGuy</dc:creator>
      <dc:date>2023-05-25T13:25:26Z</dc:date>
    </item>
    <item>
      <title>Re: how to perform lookup on CSV file from search on index</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644749#M223269</link>
      <description>&lt;P&gt;Hey Yeahnah,&lt;BR /&gt;I think I figured it out using lookup below:&lt;BR /&gt;index=table1&amp;nbsp;&lt;BR /&gt;| lookup table2.csv&amp;nbsp; ip1 as ip OUTPUTNEW ip&lt;BR /&gt;| lookup table2.csv&amp;nbsp; ip2 as ip OUTPUTNEW ip&lt;BR /&gt;| search ip1=* or ip2=*&lt;BR /&gt;| table ip, ip1, ip2, location, name&lt;BR /&gt;&lt;BR /&gt;Although I am still not sure why it worked by doing lookup twice&amp;nbsp; &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; and not sure why search work with OR instead of AND (filter out both blank ip1 and ip2)&lt;BR /&gt;And I was unable to get it to work using inputlookup&lt;BR /&gt;Thanks for your help!&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 May 2023 13:19:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644749#M223269</guid>
      <dc:creator>LearningGuy</dc:creator>
      <dc:date>2023-05-26T13:19:35Z</dc:date>
    </item>
    <item>
      <title>Re: How to perform lookup on CSV file from search on index?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644837#M223299</link>
      <description>&lt;P&gt;The inputlookup command is for something completely different - it returns the contents of your lookup file. If you want to perform a lookup, you just need to use... yes, the lookup command!&lt;/P&gt;&lt;P&gt;So your original idea was a good one, just with a wrong command&lt;/P&gt;&lt;PRE&gt;index=whatever&lt;BR /&gt;| lookup employee.csv&lt;BR /&gt;| [...]&lt;/PRE&gt;</description>
      <pubDate>Sun, 28 May 2023 10:20:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644837#M223299</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2023-05-28T10:20:11Z</dc:date>
    </item>
    <item>
      <title>Re: how to perform lookup on CSV file from search on index</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644838#M223300</link>
      <description>&lt;P&gt;To verify if something exists in a lookup it's usually better to just do the lookup and verify the results either with something like&lt;/P&gt;&lt;PRE&gt;&amp;lt;...something...&amp;gt;&lt;BR /&gt;| lookup lookup.csv lookupfield OUTPUT lookupfield AS outputfield&lt;BR /&gt;| eval found=if(outputfield==lokupfield,1,0)&lt;/PRE&gt;&lt;P&gt;Or even&lt;/P&gt;&lt;PRE&gt;&amp;lt;...something...&amp;gt;&lt;BR /&gt;| lookup lookup.csv lookupfield OUTPUT lookupfield&lt;/PRE&gt;&lt;P&gt;(In this case the field values which are not in the lookup will get nulled-out).&lt;/P&gt;&lt;P&gt;The lookup-based approach is more effective compared to inputlookup and stats because lookup is a distributable streaming command and you can still continue processing your search pipeline on the indexers whereas stats will consolidate the results and move processing to SH.&lt;/P&gt;</description>
      <pubDate>Sun, 28 May 2023 10:26:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-perform-lookup-on-CSV-file-from-search-on-index/m-p/644838#M223300</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2023-05-28T10:26:58Z</dc:date>
    </item>
  </channel>
</rss>

