create index with PARALLEL option 原理

本文介绍了一种通过并行处理来创建索引的方法。该方法首先对表进行随机采样,找到可以将索引等分为指定并行度数量的键值。接着一组查询进程扫描表,提取键值和行ID对,并将这些对发送到另一组进程。第二组进程对键值进行排序并按常规方式构建索引。最后,各部分索引由并行协调器连接形成最终的完整索引。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

CREATE INDEX indx_name ON schema.table_name(column_name) PARALLEL n;

=================================

The table is randomly sampled and a set of index keys is found that equally divides the index into the same number of pieces as the specified degree of parallelism. A first set of query processes scans the table ,extracts key,row ID pairs,and sends each pair to a process in a second set of query processes based on key.Each process in the second set sorts the keys and builds an index in the usual fashion.After all index pieces are built,the parallel coordinator concatenates the pieces (whice are ordered) to form. the final index.

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

转载于:http://blog.itpub.net/10714335/viewspace-374918/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值