lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From petite_abeille <petite_abei...@mac.com>
Subject IndexReader.delete(Term)?
Date Tue, 26 Aug 2003 19:37:47 GMT
Hello,

This is more a sanity check, than anything else, but...

I'm trying to delete a document using IndexReader.delete(Term)... (for 
the record I'm using 1.3-rc1)

The document was created with a Field.Keyword() to uniquely identify it.

The document exists, was saved, can be queried, life is good :)

But then... when trying to delete the same document later on... 
IndexReader.delete(Term) returns 0 and the document doesn't get 
deleted... which is driving me crazy 8}

Here is what I'm doing to delete the document:

     Term	aTerm = new Term( aKey, anID );

     aReader.delete( aTerm );
     aReader.close();

The term looks like the following:

szid:3FA7168800F7FDE8ECAA35500A00012D

But this doesn't seem to do anything... The document is still there no 
matter what...

I'm sure I'm doing something very wrong, but for the life of me I 
cannot see what... anything obvious I'm missing?

Thanks.

Cheers,

PA.


Mime
View raw message