<?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: Has anyone been able to create a form search that updates a lookup table? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88456#M22630</link>
    <description>&lt;P&gt;Thank you Brian!  Is there an easy solution to provide the user a way to submit?&lt;/P&gt;

&lt;P&gt;I added a SubmitButton to your example, but I'm getting an intentions error using my method:  &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;module name="HiddenSearch" autoRun="True"&amp;gt;
  &amp;lt;param name="search"&amp;gt;| inputlookup domains.csv | append [stats count | eval domain="$domain_addition$" | fields - _time | fields domain] | dedup domain |  outputlookup domains.csv&amp;lt;/param&amp;gt;
      &amp;lt;module name="SubmitButton"&amp;gt;
       &amp;lt;param name="label"&amp;gt;click to submit&amp;lt;/param&amp;gt;
      &amp;lt;module name="ViewRedirector" layoutPanel="viewHeader"&amp;gt;
        &amp;lt;param name="viewTarget"&amp;gt;flashtimeline&amp;lt;/param&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;ERROR:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;PARSER: Applying intentions failed 'unicode' object has no attribute 'get'
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 26 Apr 2011 22:06:20 GMT</pubDate>
    <dc:creator>the_wolverine</dc:creator>
    <dc:date>2011-04-26T22:06:20Z</dc:date>
    <item>
      <title>Has anyone been able to create a form search that updates a lookup table?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88452#M22626</link>
      <description>&lt;P&gt;I want to add a form field to a dashboard that would allow a user to input some text.  Somehow this text, perhaps using outputlookup, would append to a lookup table.  The only issue I see is that this text doesn't yet exist in our data until the user enters it in the form.  A bit backwards, yes.&lt;/P&gt;

&lt;P&gt;The usecase is for updating a list of domains.  We'd like to add a domain to a blacklist or a whitelist for searching.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2011 21:34:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88452#M22626</guid>
      <dc:creator>the_wolverine</dc:creator>
      <dc:date>2011-04-25T21:34:14Z</dc:date>
    </item>
    <item>
      <title>Re: Has anyone been able to create a form search that updates a lookup table?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88453#M22627</link>
      <description>&lt;P&gt;Below is one way you could add the value of an input field to a lookup file...&lt;BR /&gt;
sandbox&lt;/P&gt;

&lt;P&gt;[edited to correct syntax]&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;module name="ExtendedFieldSearch" layoutPanel="panel_row1_col1"&amp;gt;
    &amp;lt;param name="field"&amp;gt;Domain&amp;lt;/param&amp;gt;
    &amp;lt;param name="default"&amp;gt;foo.com&amp;lt;/param&amp;gt;
    &amp;lt;param name="intention"&amp;gt;
        &amp;lt;param name="name"&amp;gt;stringreplace&amp;lt;/param&amp;gt;
        &amp;lt;param name="arg"&amp;gt;
            &amp;lt;param name="domain_addition"&amp;gt;
                &amp;lt;param name="prefix"&amp;gt; &amp;lt;/param&amp;gt;
                &amp;lt;param name="fillOnEmpty"&amp;gt;True&amp;lt;/param&amp;gt;
                &amp;lt;param name="suffix"&amp;gt; &amp;lt;/param&amp;gt;
            &amp;lt;/param&amp;gt;
        &amp;lt;/param&amp;gt;
    &amp;lt;/param&amp;gt;
    &amp;lt;param name="replacementMap"&amp;gt;
        &amp;lt;param name="arg"&amp;gt;
            &amp;lt;param name="domain_addition"&amp;gt;
                &amp;lt;param name="value" /&amp;gt;
            &amp;lt;/param&amp;gt;
        &amp;lt;/param&amp;gt;
    &amp;lt;/param&amp;gt;
    &amp;lt;module name="SubmitButton"&amp;gt;
        &amp;lt;param name="label"&amp;gt;click to submit&amp;lt;/param&amp;gt;
        &amp;lt;module name="HiddenSearch"&amp;gt;
            &amp;lt;param name="search"&amp;gt;| inputlookup domains.csv | append [stats count | eval domain=trim("$domain_addition$") | fields - _time | fields domain] | dedup domain |  outputlookup domains.csv&amp;lt;/param&amp;gt;
            &amp;lt;module name="SimpleResultsTable" /&amp;gt;
        &amp;lt;/module&amp;gt;
    &amp;lt;/module&amp;gt;
&amp;lt;/module&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 26 Apr 2011 00:38:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88453#M22627</guid>
      <dc:creator>bwooden</dc:creator>
      <dc:date>2011-04-26T00:38:28Z</dc:date>
    </item>
    <item>
      <title>Re: Has anyone been able to create a form search that updates a lookup table?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88454#M22628</link>
      <description>&lt;P&gt;Using &lt;CODE&gt;stats count&lt;/CODE&gt; is better than &lt;CODE&gt;search * | head 1&lt;/CODE&gt; if you just need a dummy row. It works even if there is no data in the index (for your role or whatever), and doesn't actually even need to touch the index at all, and produces only a known field &lt;CODE&gt;count&lt;/CODE&gt;.&lt;/P&gt;</description>
      <pubDate>Tue, 26 Apr 2011 02:20:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88454#M22628</guid>
      <dc:creator>gkanapathy</dc:creator>
      <dc:date>2011-04-26T02:20:25Z</dc:date>
    </item>
    <item>
      <title>Re: Has anyone been able to create a form search that updates a lookup table?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88455#M22629</link>
      <description>&lt;P&gt;I like it and edited my response to match.  Thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 26 Apr 2011 02:29:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88455#M22629</guid>
      <dc:creator>bwooden</dc:creator>
      <dc:date>2011-04-26T02:29:53Z</dc:date>
    </item>
    <item>
      <title>Re: Has anyone been able to create a form search that updates a lookup table?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88456#M22630</link>
      <description>&lt;P&gt;Thank you Brian!  Is there an easy solution to provide the user a way to submit?&lt;/P&gt;

&lt;P&gt;I added a SubmitButton to your example, but I'm getting an intentions error using my method:  &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;module name="HiddenSearch" autoRun="True"&amp;gt;
  &amp;lt;param name="search"&amp;gt;| inputlookup domains.csv | append [stats count | eval domain="$domain_addition$" | fields - _time | fields domain] | dedup domain |  outputlookup domains.csv&amp;lt;/param&amp;gt;
      &amp;lt;module name="SubmitButton"&amp;gt;
       &amp;lt;param name="label"&amp;gt;click to submit&amp;lt;/param&amp;gt;
      &amp;lt;module name="ViewRedirector" layoutPanel="viewHeader"&amp;gt;
        &amp;lt;param name="viewTarget"&amp;gt;flashtimeline&amp;lt;/param&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;ERROR:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;PARSER: Applying intentions failed 'unicode' object has no attribute 'get'
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 26 Apr 2011 22:06:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88456#M22630</guid>
      <dc:creator>the_wolverine</dc:creator>
      <dc:date>2011-04-26T22:06:20Z</dc:date>
    </item>
    <item>
      <title>Re: Has anyone been able to create a form search that updates a lookup table?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88457#M22631</link>
      <description>&lt;P&gt;I added a submit button to my original answer while updating the method a bit.&lt;/P&gt;</description>
      <pubDate>Fri, 29 Apr 2011 21:23:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Has-anyone-been-able-to-create-a-form-search-that-updates-a/m-p/88457#M22631</guid>
      <dc:creator>bwooden</dc:creator>
      <dc:date>2011-04-29T21:23:16Z</dc:date>
    </item>
  </channel>
</rss>

