ITPub博客

首页 > Linux操作系统 > Linux操作系统 > b-tree索引

b-tree索引

原创 Linux操作系统 作者:hpevan 时间:2011-11-10 16:07:01 0 删除 编辑
索引其实就是一个二叉树的结构
 
包括根节点,分支节点,叶节点
 
索引的叶节点之间其实是一个链表的结构
 
查询索引键的最值可以在hint 中加 index_desc 或者index_asc
 
文档上的解释:index_asc 

The INDEX_ASC hint instructs the optimizer to use an index scan for the specified table. If the statement uses an index range scan, then Oracle Database scans the index entries in ascending order of their indexed values. Each parameter serves the same purpose as in "INDEX Hint".

The default behavior. for a range scan is to scan index entries in ascending order of their indexed values, or in descending order for a descending index. This hint does not change the default order of the index, and therefore does not specify anything more than the INDEX hint. However, you can use the INDEX_ASC hint to specify ascending range scans explicitly should the default behavior. change.

 

index_desc:

The INDEX_DESC hint instructs the optimizer to use a descending index scan for the specified table. If the statement uses an index range scan and the index is ascending, then Oracle scans the index entries in descending order of their indexed values. In a partitioned index, the results are in descending order within each partition. For a descending index, this hint effectively cancels out the descending order, resulting in a scan of the index entries in ascending order. Each parameter serves the same purpose as in "INDEX Hint".

 

 
 
 

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/25956376/viewspace-710765/ ,如需转载,请注明出处,否则将追究法律责任。

上一篇: 位图索引
下一篇: InnoDB 索引
请登录后发表评论 登录
全部评论

注册时间:2011-07-01

  • 博文量
    8
  • 访问量
    13296