<?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: Use Splunk SDK for Python to populate a lookup from a CSV file in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361983#M65990</link>
    <description>&lt;P&gt;Hey @aflick2486, Not sure if this helps, but here's a post on scripting a lookup with Python and the code has "import csv": &lt;A href="https://answers.splunk.com/answers/145561/how-to-script-a-lookup-in-python.html"&gt;https://answers.splunk.com/answers/145561/how-to-script-a-lookup-in-python.html&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 10 Aug 2017 20:30:35 GMT</pubDate>
    <dc:creator>lfedak_splunk</dc:creator>
    <dc:date>2017-08-10T20:30:35Z</dc:date>
    <item>
      <title>Use Splunk SDK for Python to populate a lookup from a CSV file</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361982#M65989</link>
      <description>&lt;P&gt;I would like to populate the data inside of a lookup file from a .csv on a local computer. Is there a way to use the Splunk API or Splunk SDK for Python to to do this? Let me know if you need other information.&lt;/P&gt;</description>
      <pubDate>Thu, 10 Aug 2017 18:53:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361982#M65989</guid>
      <dc:creator>aflick2486</dc:creator>
      <dc:date>2017-08-10T18:53:23Z</dc:date>
    </item>
    <item>
      <title>Re: Use Splunk SDK for Python to populate a lookup from a CSV file</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361983#M65990</link>
      <description>&lt;P&gt;Hey @aflick2486, Not sure if this helps, but here's a post on scripting a lookup with Python and the code has "import csv": &lt;A href="https://answers.splunk.com/answers/145561/how-to-script-a-lookup-in-python.html"&gt;https://answers.splunk.com/answers/145561/how-to-script-a-lookup-in-python.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Aug 2017 20:30:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361983#M65990</guid>
      <dc:creator>lfedak_splunk</dc:creator>
      <dc:date>2017-08-10T20:30:35Z</dc:date>
    </item>
    <item>
      <title>Re: Use Splunk SDK for Python to populate a lookup from a CSV file</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361984#M65991</link>
      <description>&lt;P&gt;You have to get the .csv file to the search head first, see &lt;A href="https://answers.splunk.com/answers/152485/can-you-create-modify-a-lookup-file-via-rest-api.html"&gt;this question&lt;/A&gt; and &lt;A href="https://answers.splunk.com/answers/374065/how-to-update-a-global-lookup-file-via-rest-api-fo.html"&gt;this question&lt;/A&gt;.  If you can't put the file to the search head, I would try to use the rest api to create a search with ...  | outpulookup xxx, this might work for a small file, or have a universal forwarder which indexes the local file, and then a search which reads the index and writes the .csv file with an outputlookup&lt;/P&gt;</description>
      <pubDate>Fri, 11 Aug 2017 06:41:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361984#M65991</guid>
      <dc:creator>FritzWittwer_ol</dc:creator>
      <dc:date>2017-08-11T06:41:13Z</dc:date>
    </item>
    <item>
      <title>Re: Use Splunk SDK for Python to populate a lookup from a CSV file</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361985#M65992</link>
      <description>&lt;P&gt;If you really want to maintain a lookup via the rest API the lookup has to be a kvstore lookup. CSV lookups cannot be directly modified. You can use python to read in the csv file but use the REST API to control a kvstore lookup.&lt;/P&gt;

&lt;P&gt;Similar to this:&lt;BR /&gt;
&lt;A href="https://github.com/georgestarcher/Splunk-ESIntel-KVStore"&gt;https://github.com/georgestarcher/Splunk-ESIntel-KVStore&lt;/A&gt; &lt;/P&gt;</description>
      <pubDate>Fri, 11 Aug 2017 17:22:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Use-Splunk-SDK-for-Python-to-populate-a-lookup-from-a-CSV-file/m-p/361985#M65992</guid>
      <dc:creator>starcher</dc:creator>
      <dc:date>2017-08-11T17:22:57Z</dc:date>
    </item>
  </channel>
</rss>

