设为首页 加入收藏

TOP

Oracle全文检索方面的研究(全9)(二)
2014-11-24 08:13:47 来源: 作者: 【 】 浏览:1
Tags:Oracle 全文检索 面的 研究
化问题

--先看个例子

SQL> exec ctx_ddl.optimize_index(idx_auction_db1,FULL);

PL/SQL procedure successfully completed.

Elapsed: 00:16:16.77

索引优化相当的慢,200 万的数据建立context 索引需要不到5 分钟,而优化索引居然要16 分钟,这么慢

的优化速度对一个具有几亿表的数据是很难接受的的。刚开始我以为这是oracle 的一个bug,后来查到了

一些文档。Oracle10g 引进了rebuild 优化参数,速度还是很快的。

SQL> exec ctx_ddl.optimize_index(idx_auction_db1,rebuild) ;

PL/SQL procedure successfully completed.

3.10.14 事务查询

索引可能不是实时进行同步的,但是查询又要求实时的。

--更改索引为事务性,查询再找索引时还会dr$unindexed 表,把满足条件还未索引的记录找出来

alter index idx_auction_db1 rebuild parameters(replace metadata transactional)

例子:

select count(*) from table where contains(text, someword) > 0; -- 0 hits

insert into table values (someword);

select count(*) from table where contains(text, someword) > 0; -- 1 hit (the one we just

entered)

rollback;

select count(*) from table where contains(text, someword) > 0; -- 0 hit

仅仅是对某个session 启用

exec ctx_query.disable_transactional_query := TRUE;

首页 上一页 1 2 下一页 尾页 2/2/2
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
分享到: 
上一篇MySQL下实现不区分大小写的方法 下一篇Oracle全文检索方面的研究(全7)

评论

帐  号: 密码: (新用户注册)
验 证 码:
表  情:
内  容:

·如何从内核协议栈到 (2025-12-27 03:19:09)
·什么是网络协议?有哪 (2025-12-27 03:19:06)
·TCP/ IP协议有哪些 (2025-12-27 03:19:03)
·怎样用 Python 写一 (2025-12-27 02:49:19)
·如何学习python数据 (2025-12-27 02:49:16)