title: Using the wrong escape character for Lucene lexical error at line 1 Cannot Parse Encountered <EOF>. Kentico 12
body: <p>I have a similar issue as the following question: <a href="https://stackoverflow.com/questions/39276972/lucene-error-while-parsing-query-cannot-parse-encountered-eof-at-line-1">Lucene error while parsing Query: Cannot parse '': Encountered “” at line 1, column 0</a>, and I had already tried all the escaping.  What else could it be?</p>
  
  <p>I'm using Kentico 12 hotfix 14, with their Lucene.NET 3.0.3 implementation.  My Smart Search Index uses the Standard analyzer, see below:</p>
  
  <p><a href="https://i.stack.imgur.com/cTOZd.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cTOZd.png" alt="enter image description here"></a></p>
  
  <p>I get the expected rows back when I use the following lucene syntax to pull back an en-US culture result.  This syntax is automatically created by Kentico and is needed to retrieve the correct culture.  This was directly copied from the property value.</p>
  
  <pre><code>"+_culture:([en-us TO en-us] [invariantifieldivaluei TO invariantifieldivaluei])"
  </code></pre>
  
  <p>When I add (or use alone) the following value (in many different forms - without parenthesis, etc):</p>
  
  <pre><code> "+length:(24\")"
  </code></pre>
  
  <p>I always get the Lexical error:</p>
  
  <pre><code>"Cannot parse '+_culture:([en-us TO en-us] [invariantifieldivaluei TO invariantifieldivaluei])  +length:(24\")': Lexical error at line 1, column 95.  Encountered: &lt;EOF&gt; after : \"\\\")\""
  </code></pre>
  
  <p>As you can see, I believe that I have escaped the value for the length correctly.  What am I missing here?</p>
  
  <p>Other values, that don't require escaping work just fine, such as: </p>
  
  <pre><code>+material:(nitrile)
  </code></pre>
  
  <p>Any thoughts on what I'm doing wrong with the 24" value?  Wrong analyzer?  Needed Kentico hotfix? Wrong order of filters?  Thanks for your time!</p>