You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by "Kainth, Sachin" <Sa...@atkinsglobal.com> on 2007/02/23 15:33:46 UTC

Index maintainance

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. 

[ANN]VTD-XML 2.0

Posted by Jimmy Zhang <cr...@comcast.net>.
 The VTD-XML project team is proud to announce the release of 
version 2.0 of VTD-XML, the next generation XML parser/indexer.
The new features introduced in this version are:

* VTD+XML version 1.0: the world's first true native XML index 
that is simple, general-purpose and back-compatible with XML. 
* NodeRecorder Class that saves VTDNav's cursor location for 
later sequential access.
* Overwrite capability
* Lexically comparisons between VTD and strings

 To download the software, please go to 
http://sourceforge.net/project/showfiles.php?group_id=110612

 To read the latest benchmark report please go to
http://vtd-xml.sf.net/benchmark1.html

 To get the latest API overview
http://www.ximpleware.com/vtd-xml_intro.pdf


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


RE: Index maintainance

Posted by Chris Hostetter <ho...@fucit.org>.
: I've just been looking at IndexReader and it seems you can do it using
: that, but I don't know which concrete implementation of IndexReader to
: use.

there is a static factory method for opening an IndexReader in the
IndexReader class (you can't call the constructors directly)

please go through the Lucene-Java tutorial and read the corrisponding demo
code ... it covers topics like these.

beyond that i don't know anyone who won't recomend you get a copy of LIA
and read it cover to cover...

http://lucene.apache.org/java/docs/gettingstarted.html
http://lucenebook.com/



-Hoss


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


RE: Index maintainance

Posted by "Kainth, Sachin" <Sa...@atkinsglobal.com>.
I've just been looking at IndexReader and it seems you can do it using
that, but I don't know which concrete implementation of IndexReader to
use. 

-----Original Message-----
From: Michael McCandless [mailto:lucene@mikemccandless.com] 
Sent: 23 February 2007 15:07
To: java-user@lucene.apache.org
Subject: Re: Index maintainance

Erick Erickson wrote:
> 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.

Actually as of 2.1 you can now delete and update documents through
IndexWriter.  I would recommend using IndexWriter instead of
IndexModifier.

Mike

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org



This message has been scanned for viruses by MailControl - (see
http://bluepages.wsatkins.co.uk/?6875772)


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. 

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Index maintainance

Posted by Michael McCandless <lu...@mikemccandless.com>.
Erick Erickson wrote:
> 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.

Actually as of 2.1 you can now delete and update documents through
IndexWriter.  I would recommend using IndexWriter instead of
IndexModifier.

Mike

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Index maintainance

Posted by Erick Erickson <er...@gmail.com>.
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 <Sa...@atkinsglobal.com> 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.
>