If you're using 2.1, see IndexModifier. If you're previous to 2.1, the IndexModifier is (I think), hanging around in the contrib area. You have to delete a document and re-add it, there's no such thing as "modify inplace" in lucene currently.
Erick On 2/23/07, Kainth, Sachin <[EMAIL PROTECTED]> wrote:
Hi all, Just wondering how one would perform index maintainance. I know how to add new documents: writer = new IndexWriter(IndexDirectory, new PorterAnalyzer(), false); (incidently, I wrote PorterAnalyzer myself for the PorterStemFilter since I couldn't find an analyzer using it) But what I don't know is how do we delete documents from the index and how we replace documents in the index where those documents have changed. Cheers Sachin This email and any attached files are confidential and copyright protected. If you are not the addressee, any dissemination of this communication is strictly prohibited. Unless otherwise expressly agreed in writing, nothing stated in this communication shall be legally binding. The ultimate parent company of the Atkins Group is WS Atkins plc. Registered in England No. 1885586. Registered Office Woodcote Grove, Ashley Road, Epsom, Surrey KT18 5BW. Consider the environment. Please don't print this e-mail unless you really need to.