lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Elschot <>
Subject Re: WildCardQuery
Date Tue, 21 Sep 2004 06:38:44 GMT
On Tuesday 21 September 2004 06:50, Raju, Robinson (Cognizant) wrote:
> Is there a limitation in Lucene when it comes to wildcard search ?
> Is it a problem if we use less than 3 characters along with a
> wildcard(*).
> Gives me error if I try using 45* , *34 , *3 ..etc .
> Too Many Clauses Error
> Doesn't happen if '?' is used instead of '*'.
> The intriguing thing is , that it is not consistent . 00* doesn't fail.
> Am I missing something ?

The number of clauses added to the query equals the number of
indexed terms that match the wildcard. As each clause ends up using
some buffer memory internally, a maximum was introduced to
avoid running out of memory.
You can change the maximum nr of added clauses using
BooleanQuery.setMaxClauseCount() but then it is advisable
to monitor memory usage, and evt. increase heap space for the JVM.

Paul Elschot

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message