lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Erick Erickson" <erickerick...@gmail.com>
Subject Re: neither IndexWriter nor IndexReader would delete documents
Date Mon, 19 Nov 2007 16:47:34 GMT
Also, are you re-opening the reader underlying your *searcher* before
you query and still get the deleted docs?

Also, look with Luke to see if the specific uid you *think* you've deleted
is really gone.

Best
Erick

On Nov 19, 2007 6:42 AM, Daniel Naber <lucenelist2007@danielnaber.de> wrote:

> On Sonntag, 18. November 2007, flateric wrote:
>
> > IndexReader ir = IndexReader.open(fsDir);
> > ir.deleteDocuments(new Term("uid", uid));
> > ir.close();
> >
> > Has absolutely no effect.
>
> What number does ir.deleteDocuments return? If it's 0, the uid cannot be
> found. If it's > 0: note that you need to re-open your searcher/reader to
> see any changes to your index.
>
> Regards
>  Daniel
>
> --
> http://www.danielnaber.de
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message