<?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 pull search terms from a single column csv file (for scheduled reports / dashboard) in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/pull-search-terms-from-a-single-column-csv-file-for-scheduled/m-p/478411#M82134</link>
    <description>&lt;P&gt;I have several search queries that i then save as reports (and schedule them),  they ultimately are displayed on a dashboard (some are displayed on wall monitors).&lt;/P&gt;

&lt;P&gt;Once seeing these dashboards Quite often, i have to come back and modify the query to remove some data.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;So i was hoping i could add these terms into a single column CSV file (with 1 single header), and just add new terms, and re-upload the CSV file when i need to update the query. (but i cant figure out how to do this)&lt;/STRONG&gt;   Example:&lt;/P&gt;

&lt;P&gt;original query:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=fwonly ATkc NOT src_ip="10.0.0.0/8" | search asn!=Bob asn!=frank asn!=joe
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;What im hoping for/asking:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=fwonly ATkc NOT src_ip="10.0.0.0/8" | search asn!=LIST.csv
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Im hoping, as needed i can just reupload a new LIST.csv file that contains:&lt;BR /&gt;
asn&lt;BR /&gt;
frank&lt;BR /&gt;
joe&lt;BR /&gt;
Bob&lt;BR /&gt;
new_term1&lt;BR /&gt;
new_term2&lt;/P&gt;

&lt;P&gt;and since its the LIST.csv being referenced, all my scheduled reports using LIST.csv will be updated.&lt;/P&gt;

&lt;P&gt;I think what i want is to add/upload a lookup table file,  create a CSV lookup definition (set permissions on both) and then cite/use that defined lookup table in my search query.  But i havent been able to make much headway on this.  These are the threads / docs ive been following or tried so far-&lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/50649/searching-each-line-of-a-file-against-a-splunk-index.html" target="_blank"&gt;https://answers.splunk.com/answers/50649/searching-each-line-of-a-file-against-a-splunk-index.html&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;&lt;A href="https://docs.splunk.com/Documentation/Splunk/7.0.2/Knowledge/Usefieldlookupstoaddinformationtoyourevents" target="_blank"&gt;https://docs.splunk.com/Documentation/Splunk/7.0.2/Knowledge/Usefieldlookupstoaddinformationtoyourevents&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/50649/searching-each-line-of-a-file-against-a-splunk-index.html" target="_blank"&gt;https://answers.splunk.com/answers/50649/searching-each-line-of-a-file-against-a-splunk-index.html&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;(any help is appreciated, or please do tell if this usecase is not something i should be hoping to do easily with splunk)  thanks!&lt;/P&gt;</description>
    <pubDate>Wed, 30 Sep 2020 03:34:50 GMT</pubDate>
    <dc:creator>spunk311z</dc:creator>
    <dc:date>2020-09-30T03:34:50Z</dc:date>
    <item>
      <title>pull search terms from a single column csv file (for scheduled reports / dashboard)</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/pull-search-terms-from-a-single-column-csv-file-for-scheduled/m-p/478411#M82134</link>
      <description>&lt;P&gt;I have several search queries that i then save as reports (and schedule them),  they ultimately are displayed on a dashboard (some are displayed on wall monitors).&lt;/P&gt;

&lt;P&gt;Once seeing these dashboards Quite often, i have to come back and modify the query to remove some data.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;So i was hoping i could add these terms into a single column CSV file (with 1 single header), and just add new terms, and re-upload the CSV file when i need to update the query. (but i cant figure out how to do this)&lt;/STRONG&gt;   Example:&lt;/P&gt;

&lt;P&gt;original query:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=fwonly ATkc NOT src_ip="10.0.0.0/8" | search asn!=Bob asn!=frank asn!=joe
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;What im hoping for/asking:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=fwonly ATkc NOT src_ip="10.0.0.0/8" | search asn!=LIST.csv
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Im hoping, as needed i can just reupload a new LIST.csv file that contains:&lt;BR /&gt;
asn&lt;BR /&gt;
frank&lt;BR /&gt;
joe&lt;BR /&gt;
Bob&lt;BR /&gt;
new_term1&lt;BR /&gt;
new_term2&lt;/P&gt;

&lt;P&gt;and since its the LIST.csv being referenced, all my scheduled reports using LIST.csv will be updated.&lt;/P&gt;

&lt;P&gt;I think what i want is to add/upload a lookup table file,  create a CSV lookup definition (set permissions on both) and then cite/use that defined lookup table in my search query.  But i havent been able to make much headway on this.  These are the threads / docs ive been following or tried so far-&lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/50649/searching-each-line-of-a-file-against-a-splunk-index.html" target="_blank"&gt;https://answers.splunk.com/answers/50649/searching-each-line-of-a-file-against-a-splunk-index.html&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;&lt;A href="https://docs.splunk.com/Documentation/Splunk/7.0.2/Knowledge/Usefieldlookupstoaddinformationtoyourevents" target="_blank"&gt;https://docs.splunk.com/Documentation/Splunk/7.0.2/Knowledge/Usefieldlookupstoaddinformationtoyourevents&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/50649/searching-each-line-of-a-file-against-a-splunk-index.html" target="_blank"&gt;https://answers.splunk.com/answers/50649/searching-each-line-of-a-file-against-a-splunk-index.html&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;(any help is appreciated, or please do tell if this usecase is not something i should be hoping to do easily with splunk)  thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 03:34:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/pull-search-terms-from-a-single-column-csv-file-for-scheduled/m-p/478411#M82134</guid>
      <dc:creator>spunk311z</dc:creator>
      <dc:date>2020-09-30T03:34:50Z</dc:date>
    </item>
    <item>
      <title>Re: pull search terms from a single column csv file (for scheduled reports / dashboard)</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/pull-search-terms-from-a-single-column-csv-file-for-scheduled/m-p/478412#M82135</link>
      <description>&lt;P&gt;Have you tried &lt;CODE&gt;index=fwonly ATkc NOT src_ip="10.0.0.0/8" NOT [ | inputlookup LIST.csv | fields asn | format ]&lt;/CODE&gt;?&lt;/P&gt;</description>
      <pubDate>Wed, 01 Jan 2020 19:37:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/pull-search-terms-from-a-single-column-csv-file-for-scheduled/m-p/478412#M82135</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2020-01-01T19:37:56Z</dc:date>
    </item>
    <item>
      <title>Re: pull search terms from a single column csv file (for scheduled reports / dashboard)</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/pull-search-terms-from-a-single-column-csv-file-for-scheduled/m-p/478413#M82136</link>
      <description>&lt;P&gt;awesome!  thanks so much,  that did work!    &lt;/P&gt;

&lt;P&gt;for any others in the future, all i had to do was upload the csv file, create a lookup definition,  (after which you should then see the Supported fields column update w the header from your csv file, in my case just 1x header/column).  then you can use richgalloway's [ | inputlookup LIST.csv | fields asn | format ] to pull queries from that csv file,  which makes for easy updating in the future!)&lt;/P&gt;</description>
      <pubDate>Wed, 01 Jan 2020 23:19:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/pull-search-terms-from-a-single-column-csv-file-for-scheduled/m-p/478413#M82136</guid>
      <dc:creator>spunk311z</dc:creator>
      <dc:date>2020-01-01T23:19:42Z</dc:date>
    </item>
  </channel>
</rss>

