On 11/5/2013 9:41 PM, dboychuck wrote:
> I'm having the same issue with solrJ 4.5.1
> 
> If I use the escapeQueryChars() function on a string like "a b c" it is
> escaping it to "a\+b\+c" which returns 0 results using edismax query parser.
> However "a b c" returns results.

A space is a special character to the Solr query parser.  It is a term
delimiter.  This means that if you are escaping all special characters,
you have to escape the space.

If you do not want the *entire* string treated as a single term for the
query parser, then you cannot use escapeQueryChars.  You'll need to
write your own code that is aware of the specific special characters
that you want to escape.

Thanks,
Shawn

Reply via email to