lucene-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Edoardo Marcora <>
Subject Re: Boolean query with 50,000 clauses! Possible? Scalable?
Date Sun, 26 Jul 2009 20:51:03 GMT

awarnier wrote:
> Edoardo Marcora wrote:
>> I am faced with the requirement for a boolean query composed of 50,000
>> clauses (all of them directed at the same field) all OR'ed together. 
> By pure intellectual curiosity : can you provide some idea of the type 
> of query, and the type of content of the field this is targeted at ?
> I have this notion that with 50,000 queries directed at one field, there 
> must be some smarter way of handling this than just OR-ing together the 
> results.

What I would like to do is to take the results of one query and use one of
its fields (not the docid) as an argument to another query (much like a
subquery in SQL). For example:

type:foo AND (_query_:type:bar AND field2:{field1})

This should search for all types of foo and then iterate over the result set
and perform a query for where type is bar and field2 is equal to the value
of field1 from each item of the first result set.

View this message in context:
Sent from the Lucene - General mailing list archive at

View raw message