lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "lingaraju" <lingaraju.shambulinga...@infactindia.com>
Subject Re: updating the index created for database search
Date Mon, 26 Jul 2004 11:31:28 GMT
Dear Daniel

Thanks a lot.
I do have the last-modified column in my database.
But how to know how many records are modified.
If it is new record  through which class we have to check that record is
present in the index
In the mean time I will look into IndexHTML in lucene demo

Regards
Raju

----- Original Message ----- 
From: "Daniel Naber" <daniel.naber@intrafind.de>
To: "Lucene Users List" <lucene-user@jakarta.apache.org>
Sent: Monday, July 26, 2004 3:35 PM
Subject: Re: updating the index created for database search


> On Monday 26 July 2004 11:37, lingaraju wrote:
>
> > 2) When I fetch the rows from the database in order to update or insert
in
> > index how to know which record is modified in database and which record
is
> > not present is index
>
> Your database will need a "last modified" column. Then you can select
those
> rows that have been modified since the last update and for each row check
if
> it's in the Lucene index. If it is, delete it there and re-add the new
> version. If it's not, add it. To delete documents you will probably need
to
> iterate over all your IDs in the Lucene index and check if they are still
in
> the database. If that's too inefficient you could check if you can do it
the
> way the file system indexer (IndexHTML in Lucene's demo) does it.
>
> BTW, please don't cross-post to both lists.
>
> Regards
>  Daniel
>
> -- 
> Daniel Naber, IntraFind Software AG, Tel. 089-8906 9700
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: lucene-user-help@jakarta.apache.org
>
>


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


Mime
View raw message