The steps of context install on Oracle 10g.
1, create tablespace drsys
2, run @?/ctx/admin/catctx.sql ctxsys drsys temp01 nolock
3, run @?/ctx/admin/defaults/drdefus.sql
4, grant execute on ctxsys.ctx_ddl to public
The steps of context uninstall (remove) on Oracle 10g.
-- run as sys
?/ctx/admin/catnoctx.sql
The steps of context install on Oracle 9i.
1, create tablespace drsys
2, run ?/ctx/admin/dr0csys ctxsys drsys temp01
3, conn to ctxsys user
4, run ?/ctx/admin/dr0inst ?/ctx/lib/libctxx9.so
5, run ?/ctx/admin/defaults/drdefus.sql
6, grant execute on ctxsys.ctx_ddl to public;
The steps of context uninstall (remove) on Oracle 9i.
-- run as ctxsys
$ORACLE_HOME/ctx/admin/dr0drop.sql
-- run as sys
$ORACLE_HOME/ctx/admin/dr0dsys.sql
Verification of the context installation.
-- check dba_registry
col version format a14
col comp_name format a30
select COMP_NAME,VERSION,STATUS from dba_registry;
-- Create a sample table
create table cr_ctxdemo (col1 number not null primary key, col2 varchar2(100));
insert into cr_ctxdemo values (1,'Oracle A B C');
commit;
create index idx_cr_ctxdemo_col2 on cr_ctxdemo(col2) indextype is ctxsys.context;
select col1 from cr_ctxdemo where contains(col2,'A or C') > 0;
set autot trace exp
select col1 from cr_ctxdemo where contains (col2,'A') > 0;
set autot off
drop table cr_ctxdemo;
Context index can be considered as a text search tool.
