<?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: Update Lookup csv by Splunk Output in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690948#M235314</link>
    <description>&lt;P&gt;I think the OP's&amp;nbsp;test_MID_IP.csv contains &lt;U&gt;test_IP&lt;/U&gt;, not &lt;EM&gt;IP&lt;/EM&gt;. (Although it doesn't need to be.) &amp;nbsp;It doesn't need &lt;U&gt;count&lt;/U&gt;&amp;nbsp;but may (or may not) need &lt;U&gt;MID&lt;/U&gt;. &amp;nbsp;Also, &amp;nbsp;the append option is needed for the table preserve all data.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=abc IP!="10.*" 
[| inputlookup ip_tracking.csv | rename test_DATA AS MID | format ] 
| lookup test_MID_IP.csv test_IP as IP OUTPUT test_IP 
| where isnull(test_IP)
| dedup IP
| rename IP as test_IP
| fields test_IP MID ``` omit MID if that's not needed ```
| outputlookup append=true test_MID_IP.csv&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 18 Jun 2024 04:57:19 GMT</pubDate>
    <dc:creator>yuanliu</dc:creator>
    <dc:date>2024-06-18T04:57:19Z</dc:date>
    <item>
      <title>Update Lookup csv by Splunk Output</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690879#M235296</link>
      <description>&lt;P&gt;How i update the&amp;nbsp;test_MID_IP.csv&amp;nbsp; with the output IP, so that next time it runs with updated list&lt;/P&gt;&lt;PRE&gt;index=abc IP!="10.*" [| inputlookup ip_tracking.csv &lt;BR /&gt;  | rename test_DATA AS MID | format ] &lt;BR /&gt;| lookup test_MID_IP.csv test_IP as IP OUTPUT test_IP &lt;BR /&gt;| eval match=if('IP'== test_IP, "yes", "no")&lt;BR /&gt;| search match=no &lt;BR /&gt;| stats count by IP&lt;/PRE&gt;</description>
      <pubDate>Mon, 17 Jun 2024 12:16:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690879#M235296</guid>
      <dc:creator>RahulMisra1</dc:creator>
      <dc:date>2024-06-17T12:16:11Z</dc:date>
    </item>
    <item>
      <title>Re: Update Lookup csv by Splunk Output</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690894#M235297</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/267451"&gt;@RahulMisra1&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the outputlookup command is used to write the lookup file (we can overwrite or append the lookup file)&lt;/P&gt;&lt;P&gt;Pls note - this one overwrites the lookup file..&amp;nbsp; if you want to append, pls let us know..&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=abc IP!="10.*" 
[| inputlookup ip_tracking.csv | rename test_DATA AS MID | format ] 
| lookup test_MID_IP.csv test_IP as IP OUTPUT test_IP 
| eval match=if('IP'== test_IP, "yes", "no")
| search match=no 
| stats count by IP
| outputlookup test_MID_IP.csv&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 17 Jun 2024 12:20:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690894#M235297</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2024-06-17T12:20:02Z</dc:date>
    </item>
    <item>
      <title>Re: Update Lookup csv by Splunk Output</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690901#M235299</link>
      <description>&lt;P&gt;Thanks. I want to append the IP to the existing lookup&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;test_MID_IP.csv&lt;/PRE&gt;</description>
      <pubDate>Mon, 17 Jun 2024 12:53:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690901#M235299</guid>
      <dc:creator>RahulMisra1</dc:creator>
      <dc:date>2024-06-17T12:53:47Z</dc:date>
    </item>
    <item>
      <title>Re: Update Lookup csv by Splunk Output</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690948#M235314</link>
      <description>&lt;P&gt;I think the OP's&amp;nbsp;test_MID_IP.csv contains &lt;U&gt;test_IP&lt;/U&gt;, not &lt;EM&gt;IP&lt;/EM&gt;. (Although it doesn't need to be.) &amp;nbsp;It doesn't need &lt;U&gt;count&lt;/U&gt;&amp;nbsp;but may (or may not) need &lt;U&gt;MID&lt;/U&gt;. &amp;nbsp;Also, &amp;nbsp;the append option is needed for the table preserve all data.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=abc IP!="10.*" 
[| inputlookup ip_tracking.csv | rename test_DATA AS MID | format ] 
| lookup test_MID_IP.csv test_IP as IP OUTPUT test_IP 
| where isnull(test_IP)
| dedup IP
| rename IP as test_IP
| fields test_IP MID ``` omit MID if that's not needed ```
| outputlookup append=true test_MID_IP.csv&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 18 Jun 2024 04:57:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Update-Lookup-csv-by-Splunk-Output/m-p/690948#M235314</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2024-06-18T04:57:19Z</dc:date>
    </item>
  </channel>
</rss>

