Format of Index Blocks (207)

tsinglee發表於2007-11-16

Space available for index data is the Oracle block size minus block overhead, entry
overhead, rowid, and one length byte for each value indexed.

When you create an index, Oracle fetches and sorts the columns to be indexed and
stores the rowid along with the index value for each row. Then Oracle loads the index
from the bottom up. For example, consider the statement:
CREATE INDEX employees_last_name ON employees(last_name);

Oracle sorts the employees table on the last_name column. It then loads the index
with the last_name and corresponding rowid values in this sorted order. When it
uses the index, Oracle does a quick search through the sorted last_name values and
then uses the associated rowid values to locate the rows having the sought last_
name value.

索引格式
1. 索引資料段可用空間由資料塊大小減去塊開銷 , 條目開銷 ,rowid , 索引長度值(1位)
2. 建立索引的時候 ,Oracle取得並排序要建立索引的列 ,
將rowid和索引值儲存起來按從下到上的順序載入到索引中

[@more@]

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/10599713/viewspace-982563/,如需轉載,請註明出處,否則將追究法律責任。

相關文章