Iterate through all Hits for "city:city1 AND
state:state1" and delete
them by document ID.
Erik
On Sep 26, 2006, at 10:04 PM, Josh Joy wrote:
> Hi All,
>
> I need to delete from the index where 2 terms are
> matching, rather than
> just one term.
> For example,
>
> IndexReader reader = IndexReader.open(dir);
> Term[] terms = new Term[2];
> terms[0] = new
Term("city","city1");
> terms[1] = new
Term("state","state1");
> reader.delete(terms);
> reader.close();
>
> Any suggestions?
>
> Thanks in advance,
> Josh
>
>
------------------------------------------------------------
---------
> To unsubscribe, e-mail: java-user-unsubscribe lucene.apache.org
> For additional commands, e-mail: java-user-help lucene.apache.org
------------------------------------------------------------
---------
To unsubscribe, e-mail: java-user-unsubscribe lucene.apache.org
For additional commands, e-mail: java-user-help lucene.apache.org
|