<?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: query with taken safe in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186687#M11580</link>
    <description>&lt;P&gt;I have done a spelling mistake writing here, but in the code is correct, the name of the token  is always the same per recurrence. &lt;BR /&gt;
How can I solve this?&lt;/P&gt;</description>
    <pubDate>Fri, 20 Mar 2015 09:17:09 GMT</pubDate>
    <dc:creator>Federica_92</dc:creator>
    <dc:date>2015-03-20T09:17:09Z</dc:date>
    <item>
      <title>query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186681#M11574</link>
      <description>&lt;P&gt;Hi everyone, I'm trying to do a query using eval, and a token value:&lt;BR /&gt;
     ....&lt;BR /&gt;
     var id = $(cb).attr('id');&lt;BR /&gt;
     tokens.set("mytoken", id);&lt;/P&gt;

&lt;P&gt;But the query is not working, if instead of write "mytoken" in the eval condition, I write it at the place of the * the query works. Any suggestion?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;  var SearchManager_button = require("splunkjs/mvc/searchmanager");
  new SearchManager_button({
                    id: "mysearch-button",
                    search: mvc.tokenSafe ("*| eval output=$mytoken$ | fields output |outputlookup wildcard_read.csv")
            });
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 16 Mar 2015 14:36:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186681#M11574</guid>
      <dc:creator>Federica_92</dc:creator>
      <dc:date>2015-03-16T14:36:15Z</dc:date>
    </item>
    <item>
      <title>Re: query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186682#M11575</link>
      <description>&lt;P&gt;"mvc.tokenSafe :(" is not valid syntax. You have an extra colon. Please check JS console for errors.&lt;/P&gt;</description>
      <pubDate>Mon, 16 Mar 2015 17:25:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186682#M11575</guid>
      <dc:creator>dfoster_splunk</dc:creator>
      <dc:date>2015-03-16T17:25:16Z</dc:date>
    </item>
    <item>
      <title>Re: query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186683#M11576</link>
      <description>&lt;P&gt;Sorry, you are right, I have correct the syntax, but I have still the same problem, I have got that I cannot use :&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; | eval output=$radiogroup$
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;So, I cannot use the tokensafe in the second part of the query but I don't understand the reason. &lt;BR /&gt;
Let me know, if you will have any ideas, thank you&lt;/P&gt;</description>
      <pubDate>Wed, 18 Mar 2015 11:02:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186683#M11576</guid>
      <dc:creator>Federica_92</dc:creator>
      <dc:date>2015-03-18T11:02:59Z</dc:date>
    </item>
    <item>
      <title>Re: query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186684#M11577</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;P&gt;So, I cannot use the tokensafe in the second part of the query&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;P&gt;I do not understand what you mean by this. It is valid to pass an expression of the form tokensafe("&lt;STRONG&gt;SEARCH_STRING&lt;/STRONG&gt;") to a setting for a SearchManager.&lt;/P&gt;

&lt;P&gt;Depending on how much you are omitting from your example, you may need to update "submitted" token model in addition to the "default" token model. Any SearchManager emitted from Simple XML will be bound to the "submitted" token model by default. However the code example you provide doesn't have the SearchManager bound to "submitted", so this may not be your issue.&lt;/P&gt;</description>
      <pubDate>Wed, 18 Mar 2015 18:59:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186684#M11577</guid>
      <dc:creator>dfoster_splunk</dc:creator>
      <dc:date>2015-03-18T18:59:56Z</dc:date>
    </item>
    <item>
      <title>Re: query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186685#M11578</link>
      <description>&lt;P&gt;I mean, if I use $radiougroup$ before of the pipe " | " My query read the value of the token, instead if I use the pipe, and next eval, my query doesn't recognize it.&lt;/P&gt;

&lt;P&gt;I have tried to add this part :&lt;BR /&gt;
     {tokens: true, tokenNamespace: "submitted"}&lt;/P&gt;

&lt;P&gt;Based of the submitted models, but still doesn't work&lt;/P&gt;</description>
      <pubDate>Thu, 19 Mar 2015 11:20:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186685#M11578</guid>
      <dc:creator>Federica_92</dc:creator>
      <dc:date>2015-03-19T11:20:04Z</dc:date>
    </item>
    <item>
      <title>Re: query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186686#M11579</link>
      <description>&lt;P&gt;Check your spelling. $radiogroup$ != $radiougroup$.&lt;/P&gt;

&lt;P&gt;If you add {tokenNamespace: "submitted"} then updating the "default" model, as you current code does, will have no effect. You probably don't want {tokenNamespace: "submitted"}.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Mar 2015 17:21:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186686#M11579</guid>
      <dc:creator>dfoster_splunk</dc:creator>
      <dc:date>2015-03-19T17:21:15Z</dc:date>
    </item>
    <item>
      <title>Re: query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186687#M11580</link>
      <description>&lt;P&gt;I have done a spelling mistake writing here, but in the code is correct, the name of the token  is always the same per recurrence. &lt;BR /&gt;
How can I solve this?&lt;/P&gt;</description>
      <pubDate>Fri, 20 Mar 2015 09:17:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186687#M11580</guid>
      <dc:creator>Federica_92</dc:creator>
      <dc:date>2015-03-20T09:17:09Z</dc:date>
    </item>
    <item>
      <title>Re: query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186688#M11581</link>
      <description>&lt;P&gt;Based on the information provided I don't see anything you're doing incorrectly.&lt;/P&gt;

&lt;P&gt;Sounds like you need some hands-on debugging assistance. If you have Support contract with Splunk I would suggest opening up a Support case.&lt;/P&gt;</description>
      <pubDate>Fri, 20 Mar 2015 17:50:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186688#M11581</guid>
      <dc:creator>dfoster_splunk</dc:creator>
      <dc:date>2015-03-20T17:50:43Z</dc:date>
    </item>
    <item>
      <title>Re: query with taken safe</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186689#M11582</link>
      <description>&lt;P&gt;I don't think something like that, I'm sure that there will be a different syntax to use the value $mytoken$ in a position that is not the first in the query&lt;/P&gt;</description>
      <pubDate>Mon, 23 Mar 2015 09:27:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/query-with-taken-safe/m-p/186689#M11582</guid>
      <dc:creator>Federica_92</dc:creator>
      <dc:date>2015-03-23T09:27:42Z</dc:date>
    </item>
  </channel>
</rss>

