Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Incremental indexing in Oracle Text

Re: Incremental indexing in Oracle Text

From: John Russell <netnews6_at_johnrussell.mailshell.com>
Date: Thu, 31 Jul 2003 20:59:19 GMT
Message-ID: <7nuiiv48ps7rhl0bloa7mqblj5hddqlof4@4ax.com>


On Thu, 31 Jul 2003 13:24:06 GMT, Russell Lear <russelllear_at_earthlink.net> wrote:
>We're using Oracle 9i to hold a moderate to large number of documents (>
>100,000). We'd like to use Oracle Text to do this, but we do have some
>concerns on indexing performance.
>
>If documents are coming in at an average of one every 2 - 3 seconds and we
>want the index to be up to date, can we reindex after every document? Or
>would the time spent on indexing swamp the machine? Is Oracle's indexing
>smart enough to see that a document hasn't changed and so not re-scan it?
>
>Alternatively, is there a way to specify exactly which files to add to the
>index?
>
>I've looked through the documentation on OTN (and it actually is quite
>complete and thorough, especially on configuring), but haven't seen a
>discussion of how to control this aspect of indexing. (And I may well have
>missed it - there's a lot there).

I don't know about the performance side, since I do my index updates in batches.

The way to update only the changed rows in the index is the PL/SQL procedure CTX_DDL.SYNC_INDEX('<index_name>'). I use a FILE_DATASTORE where the primary key of my table holds the names of the files with the text. If I need to just replace part of the index, I'll do

update <table> set <indexed_column> = <indexed_column> where ... exec ctx_ddl.sync_index('<my_index>');
(Doesn't matter if the above UPDATE is rolled back or not.)

I presume the same would work if my column held the actual text being indexed. Not sure if there are extra considerations for LOB columns.

John

--
Photo gallery: http://www.pbase.com/john_russell/
Received on Thu Jul 31 2003 - 15:59:19 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US