Updating lucene index

But I would like to update the index database next time I run Indexer rather than deleting the database and creating index from scratch every time I run the Indexer. Any help appreciated, Thanks, Madhavi Kodumuri You mean, whenever I have updated the document which is already indexed have to be deleted first from the index database and then add that document to my indexer.

I think this method is wrapped in Index Modifier as well, not sure. your Index Reader.delete(new Term("your Unique Field", "your Unique Value")); Fredrik On 1/26/06, Kodumuri, Madhavi Looks OK to me.This is my snippet, can you please let me know what I was doing wrong.Index_path is the path for the index database url is the one of the Field in my Documents I added, Directory dir = Directory(index_path, false); reader = reader.open(dir); if (reader !Thanks, Koji You can delete by any unique term, using an Index Reader.I think this method is wrapped in Index Modifier as well, not sure. your Index Reader.delete(new Term("your Unique Field", "your Unique Value")); Fredrik On 1/26/06, Kodumuri, Madhavi I tried doing this, but I guess I am doing something wrong.

Search for updating lucene index:

updating lucene index-57updating lucene index-22

Leave a Reply

Your email address will not be published. Required fields are marked *

One thought on “updating lucene index”