On Tuesday 15 November 2005 20:30, Doug Cutting wrote:
> Paul Elschot wrote:
> > Not using the document term frequencies in PrefixQuery would still
> > leave these as a surprise factor between PrefixQuery and TermQuery.
> 
> Should we dynamically decide to switch to FieldNormQuery when 
> BooleanQuery.maxClauseCount is exceeded?  That way queries that 
> currently work would continue to work, and queries that formerly failed 
> would now work.  How complicated would this be to implement?

Why not leave that decision to the program using the query?
Something like this:
- catch the TooManyClauses exception,
-  adapt (the offending parts of) the query to make these use
   a FieldNormQuery, 
- retry with a warning to the provider of the query that 
  the term frequencies have been ignored.

The only disadvantage of this is that the term expansion
during rewrite has to be redone.
Also, when enough terms are involved, they might still cause
a memory problem because they are all needed at the same
time.

Regards,
Paul Elschot


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to