I'm having several problems with deleting documents with Lucene 2.2.
Via the IndexWriter, I can successfully delete a document by its primary
key via a Term, but ONLY if the field was stored as
Field.Index.UN_TOKENIZED. If it was stored as TOKENIZED, the debug output
says it is deleting the do
Nick, are you opening a new IndexSearcher after you close the IndexWriter?
-Yonik
On 7/4/07, Nick Johnson <[EMAIL PROTECTED]> wrote:
I'm having several problems with deleting documents with Lucene 2.2.
Via the IndexWriter, I can successfully delete a document by its primary
key via a Term, but
This is exactly the behavior I'd expect.
Consider what would happen otherwise. Say you have documents
with the following values for a field (call it blah).
some data
some data I put in the index
lots of data
data
Then I don't want deleting on the term blah:data to remove all
of them. Which seems
I am.
On Wed, 4 Jul 2007, Yonik Seeley wrote:
> Nick, are you opening a new IndexSearcher after you close the IndexWriter?
--
"Courage isn't just a matter of not being frightened, you know. It's being
afraid and doing what you have to do anyway."
Doctor Who - Planet of the Daleks
This messa
I think I follow you. I don't have a problem with storing something like
a primary key as UN_TOKENIZED, though I'm a bit baffled about why it
didn't work as TOKENIZED, since the _only_ thing in that field is the
value of the primary key (ie, the string value of some integer). It seems
like it
See below
On 7/4/07, Nick Johnson <[EMAIL PROTECTED]> wrote:
I think I follow you. I don't have a problem with storing something like
a primary key as UN_TOKENIZED, though I'm a bit baffled about why it
didn't work as TOKENIZED, since the _only_ thing in that field is the
value of the primary
A little more digging and I found the problem (amazing what coffee can
do). It was a bad assertion in my unit test. Basically I was checking to
see that the article was indexed after the update, but didn't check to see
whether it was indexed BEFORE the update. It wasn't. Or rather, it was,
On Wed, Jul 04, 2007, Erick Erickson wrote about "Re: problems with
deleteDocuments":
> Consider what would happen otherwise. Say you have documents
> with the following values for a field (call it blah).
> some data
> some data I put in the index
> lots of data
>
'El <[EMAIL PROTECTED]> wrote:
On Wed, Jul 04, 2007, Erick Erickson wrote about "Re: problems with
deleteDocuments":
> Consider what would happen otherwise. Say you have documents
> with the following values for a field (call it blah).
> some data
> some data I put in t