Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: ConText GIST and Index w/o storing the document?
To index a file external from the database, you need to specify this when creating the ConText policy. Simply specify 'CTXSYS.DEFAULT_OSFILE' as the datastore preference.
As an example, to create a policy on a column (column will contain the 'pointer' to the actual document):
exec CTX_DDL.CREATE_POLICY( 'mytable', 'mytable.column', dstore_pref=>'CTXSYS.DEFAULT_OSFILE');
In this case, mytable.column can be of data type VARCHAR2, since it's only going to used to store the file specification.
You can control deletion of the gists through a database trigger. That is, when deleting a row from the document table, delete the corresponding rows from the gists table, referenced by the document primary key.
Keep in mind that if you delete the source documents, procedures like CTX_QUERY.HIGHLIGHT will not work properly, as they rely upon the source document.
On Wed, 01 Oct 1997 14:56:57 GMT,
Gerhard.Moeller_at_OFFIS.Uni-Oldenburg.de (Gerhard Moeller) wrote:
>Hi,
>
>I would like to create GISTs and ConText Indices from documents but do
>NOT want to store the documents itself, rather I want to store just a
>pointer where to get them. (Of course I hold the documents during the
>indexing, but afterwards I want to delete them savely from the server,
>without deleting their indices and GISTs.)
>
>Only if I delete the pointer to some document I want to delete its
>GIST and index as well.
>
>Can that be done? Did anyone do such a thing already?
>
> Thaks for any hint and help,
>
> Gerhard.
>
Thanks!
Joel
Joel R. Kallman Enabling the Information Age! Oracle Government, Education, & Health Bethesda, MD http://govt.us.oracle.com jkallman@us.oracle.com http://www.oracle.com