Tank your Michael for sharing your patch! It was really helpful, but for our particular requirement a SearchComponent that rewrites our query is enough (as suggested by Alexandre, although thanks a lot), basically we just escape a bunch of * that we know are "problematic".
This approach allow us to quietly avoid the wildcard query and instead use it as a normal term query, instead of throwing a SyntaxError which is more convenient in our case. Regards, ----- Original Message ----- From: "Michael F. Ryan (LNG-DAY)" <michael.r...@lexisnexis.com> To: solr-user@lucene.apache.org Sent: Friday, January 23, 2015 8:26:48 AM Subject: RE: Avoiding wildcard queries using edismax query parser Here's a Jira for this: https://issues.apache.org/jira/browse/SOLR-3031 I've attached a patch there that might be useful for you. -Michael -----Original Message----- From: Jorge Luis Betancourt González [mailto:jlbetanco...@uci.cu] Sent: Thursday, January 22, 2015 4:34 PM To: solr-user@lucene.apache.org Subject: Avoiding wildcard queries using edismax query parser Hello all, Currently we are using edismax query parser in an internal application, we've detected that some wildcard queries including "*" are causing some performance issues and for this particular case we're not interested in allowing any user to request all the indexed documents. This could be easily escaped in the application level, but right now we have several applications (using several programming languages) consuming from Solr, and adding this into each application is kind of exhausting, so I'm wondering if there is some configuration that allow us to treat this special characters as normal alphanumeric characters. I've tried one solution that worked before, involving the WordDelimiterFilter an the types attribute: <filter class="solr.WordDelimiterFilterFactory" generateWordParts="0" generateNumberParts="0" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="0" preserveOriginal="0" types="characters.txt" /> and in characters.txt I've mapped the special characters into ALPHA: + => ALPHA * => ALPHA Any thoughts on this? --------------------------------------------------- XII Aniversario de la creación de la Universidad de las Ciencias Informáticas. 12 años de historia junto a Fidel. 12 de diciembre de 2014. --------------------------------------------------- XII Aniversario de la creación de la Universidad de las Ciencias Informáticas. 12 años de historia junto a Fidel. 12 de diciembre de 2014.