创建索引后,如果数据量大,如何能解决同步索引慢的问题!!
SQL> create index ind_person on person(info) indextype is ctxsys.context
2 parameters('lexer ctxsys.test_chinese_lexer'); 由于数据量比较大,用上面语句创建索引用了30多分钟,终于创建完成了,但是使用
ctx_ddl.sync_index('ind_person','50M');
ctx_ddl.optimize_index('ind_person','FULL');同步和优化索引也是非常慢,请问有没有好的解决办法??
SQL> create index ind_person on person(info) indextype is ctxsys.context
2 parameters('lexer ctxsys.test_chinese_lexer'); 由于数据量比较大,用上面语句创建索引用了30多分钟,终于创建完成了,但是使用
ctx_ddl.sync_index('ind_person','50M');
ctx_ddl.optimize_index('ind_person','FULL');同步和优化索引也是非常慢,请问有没有好的解决办法??
ctx_ddl.optimize_index('ind_person','FULL', parallel_degree=>2);
ctx_ddl.optimize_index('ind_person','FULL'); 我还发现了个问题,用上面的语句同步优化已经建好的索引,非常慢,还不如drop index后再重建快呢?请问是这样吗?
我反复测试得出了这么个结果。
ctx_ddl.sync_index('ind_person','50M'); ctx_ddl.optimize_index('ind_person','FULL'); 用上面语句同步,速度还可以;优化的素的非常慢。