Parallel index_ffs?

November 12th, 2007 | Categories: Book | Tags:

查询某个表记录总数的时候,往往基于primary key的index fast full scan是最有效的。如果索引仍然很大的话,index fast full scan仍然需要等待一些时间,如果并行查询,应该能够减少在屏幕前等待的时间。

非常遗憾,parallel hint对index_ffs不起作用,至少在10g中是这样的(IOT和rebuild index例外).

要在普通表上使用 index fast full scan进行并行查询,只能如此:

alter index test_pk parallel N;
select /*+ index_ffs(test_pk) */count(*) from test;

但这个DDL挺让人讨厌的。希望oracle能够增强parallel_index这个hint.
9i文档上有段交待,


Fast Full Index Scan Restrictions

Fast full index scans have the following restrictions:

At least one indexed column of the table must have the NOT NULL constraint.

There must be a parallel clause on the index if you want to perform a fast full index scan in parallel. The parallel degree of the index is set independently. The index does not inherit the degree of parallelism of the table.

You must have analyzed the index; otherwise, the optimizer might decide not to use it.

Del.icio.us Google书签 Digg Live Bookmark Technorati Furl Yahoo书签 Facebook 百度搜藏 新浪 ViVi 365Key 网摘 天极网摘 和讯网摘 博拉网 POCO 网摘 饭否 QQ 书签 Digbuzz 我挖网 Mister Wong
No comments yet.