Updating documents

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Updating documents

Markus Wiederkehr
Hi all,

I would like to update a document as follows.

1) retrieve the document from an IndexReader/Searcher
2) delete the document
3) manipulate the document, that is remove and add fields
4) save the document using an IndexWriter

When I do this all fields that were indexed and/or tokenized but not
stored get lost.

So is there any way to preserve fields that were not stored?
Reconstructing these fields is to expensive in my application.

Thanks in advance,

Markus

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Updating documents

Chris Hostetter-3

: When I do this all fields that were indexed and/or tokenized but not
: stored get lost.
:
: So is there any way to preserve fields that were not stored?
: Reconstructing these fields is to expensive in my application.

"preserving" those fields is pretty much the oposite of "not storing"
them.

i think some people have discussed the idea of using the term vector info
to reconstruct the token stream to recreate a doc with identical
properties from a search perspective, but in general, the most straight
forward way to achieve what you want is to store every field.



-Hoss


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]