PostgreSQL sixth class

  1. 一维索引

primary: index on unique field, may be sorted on A
clustering: index on non-unique field, file sorted on A
secondary: file not sorted on A

dense: every tuple is referenced by an entry in the index file
sparse: only some tuples are referenced by index file entries
single-level: tuples are accessed directly from the index file
multi-level: may need to access several index pages to reach tuple

一般情况下,主键索引都是dense的,index file 是 sorted。

  1. index
    Data file sorted: primary index
    Data file sorted but one index for each key values
    clustering index
    Data file unsorted: secondary index

  2. B + tree
    类似 2 3 4 tree
    但是可以有重复node在这里插入图片描述

  3. n 维索引

  4. bit-map index

  5. MA hashing

    choice vector
    多列构成近似一个唯一的hash值
    cv是可以配置的
    notice: range query 在 hash 情况下 不起优化作用
    所有内容都是由规定好的cv生成的对应的hash

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值