<?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: Failed to parse templatized search for field.... in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432157#M123475</link>
    <description>&lt;P&gt;is that a JSON format data?&lt;BR /&gt;
look into the &lt;CODE&gt;| spath&lt;/CODE&gt; command&lt;/P&gt;</description>
    <pubDate>Fri, 15 Mar 2019 14:36:00 GMT</pubDate>
    <dc:creator>adonio</dc:creator>
    <dc:date>2019-03-15T14:36:00Z</dc:date>
    <item>
      <title>Failed to parse templatized search for field....</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432156#M123474</link>
      <description>&lt;P&gt;Hi.&lt;/P&gt;

&lt;P&gt;I wonder whether someone may be able to help me please.&lt;/P&gt;

&lt;P&gt;I'm using the query below:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| multisearch
[ search `gateway_wmf(APIClientRequest)` path=*test*]
[ search `wso2_wmf(APIRequestCompleted)` "request.detail.Context"=*test]
| eval RequestID=coalesce('request.tags.X-Request-ID','requestID')
| rename request.detail.applicationProductionClientId as ClientID 
| lookup consumercalls.csv ClientID OUTPUT Developer
| eval header=""
| foreach clientHeaders.test* [eval header=header+test&amp;lt;&amp;lt;MATCHSTR&amp;gt;&amp;gt;]
| bucket span=10s _time
| chart values(ClientID) as ClientID sum(clientHeaders.test*) as clientHeaders.test* by RequestID
| fields - RequestID
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The query works except that on random days when I receive this error:&lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;Failed to parse templatized search for field  'clientHeaders.test-client-device-id{}'&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;P&gt;From comparing these dates I've discovered that it's because the fieldname has the {}.&lt;/P&gt;

&lt;P&gt;Could someone tell me please is there a way to get around this?&lt;/P&gt;

&lt;P&gt;Many thanks and kind regards&lt;/P&gt;

&lt;P&gt;Chris&lt;/P&gt;</description>
      <pubDate>Thu, 14 Mar 2019 14:46:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432156#M123474</guid>
      <dc:creator>IRHM73</dc:creator>
      <dc:date>2019-03-14T14:46:34Z</dc:date>
    </item>
    <item>
      <title>Re: Failed to parse templatized search for field....</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432157#M123475</link>
      <description>&lt;P&gt;is that a JSON format data?&lt;BR /&gt;
look into the &lt;CODE&gt;| spath&lt;/CODE&gt; command&lt;/P&gt;</description>
      <pubDate>Fri, 15 Mar 2019 14:36:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432157#M123475</guid>
      <dc:creator>adonio</dc:creator>
      <dc:date>2019-03-15T14:36:00Z</dc:date>
    </item>
    <item>
      <title>Re: Failed to parse templatized search for field....</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432158#M123476</link>
      <description>&lt;P&gt;Hi @adonio. Thank you for coming back to me with this.&lt;/P&gt;

&lt;P&gt;Yes the data is in a JSON style format, but this is a fieldname and not data which I have an issue with.&lt;/P&gt;

&lt;P&gt;Many thanks and kind regards&lt;/P&gt;

&lt;P&gt;Chris&lt;/P&gt;</description>
      <pubDate>Tue, 19 Mar 2019 07:25:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432158#M123476</guid>
      <dc:creator>IRHM73</dc:creator>
      <dc:date>2019-03-19T07:25:09Z</dc:date>
    </item>
    <item>
      <title>Re: Failed to parse templatized search for field....</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432159#M123477</link>
      <description>&lt;P&gt;I saw a similar message below&lt;BR /&gt;
[splunk-idx1] Failed to parse templatized search for field 'tag::eventtype'&lt;/P&gt;

&lt;P&gt;This error was caused by following forearch command.&lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;| foreach * &lt;BR /&gt;
    [ eval &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; = if(isnull(&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;),"",&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;)]&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;I think the &amp;lt;&amp;gt; template cannot handle fields contains special characters. I worked around this by adding &lt;CODE&gt;| fields - tag::eventtype&lt;/CODE&gt; just before the foreach.&lt;BR /&gt;
You can probably work  around by adding &lt;CODE&gt;| fields - 'clientHeaders.test-client-device-id{}'&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 21 Aug 2019 09:23:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Failed-to-parse-templatized-search-for-field/m-p/432159#M123477</guid>
      <dc:creator>tmurata_splunk</dc:creator>
      <dc:date>2019-08-21T09:23:16Z</dc:date>
    </item>
  </channel>
</rss>

