lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael D. Curtin" <>
Subject Re: Lucene and database
Date Tue, 04 Jul 2006 15:21:01 GMT
Alexander Mashtakov wrote:

> But, the database is going to be big enough, and the list of IDs 
> returned by
> Lucene too. This
> may cause high memory usage and slow sql query speed (for instance 1000 IDs
> in "IN (id1, id2 ...)"
> sql filter)

For this part, I recommend using a working table to hold the IDs that result 
from your Lucene search, then use a join instead of the IN operator in your 
SQL query.  Oracle/Sybase/SQLServer all have array capabilities in their APIs 
that make an insertion of a 1000 integers pretty darn fast, so I'm guessing 
that MySQL has such a thing too.

Good luck!


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

View raw message