索引分区

来源:互联网 发布:蒙语歌曲软件 编辑:程序博客网 时间:2024/05/20 11:49

局部索引分区
全局索引分区

局部索引分区可以随对应表的变化而变化,所以它比全局索引需要的维护要少。
全局索引进行分区时与其对应的表无关。即使索引对应的表没有进行分区,也可对一个全局索引进行分区,独立性。

 

create index test_id_idx on test(id) global partition by
range (id)
(partition p1 values less than (112),
partition p2 values less than (223),
partition p3 values less than (334),
partition p4 values less than (maxvalue)
)
/

 

create index test_id_222idx on test(name) global partition by
hash (name)
partitions 10 store in (users)
/


create index idx on test(ttt) global partition by
hash (ttt)
(partition p1 tablespace users,
partition p2 tablespace users)
/

 

原创粉丝点击