聚簇索引与非聚簇索引
时间: 2024-02-20 22:25:38 浏览: 67
详解MySQL 聚簇索引与非聚簇索引
聚簇索引与非聚簇索引是数据库中的两种不同的索引类型。聚簇索引是对磁盘上实际数据重新组织以按指定的一个或多个列的值排序的算法,存储数据的顺序和索引顺序一致。一般情况下主键会默认创建聚簇索引,且一张表只允许存在一个聚簇索引。而非聚簇索引的叶子节点仍然是索引节点,只不过有指向对应数据块的指针。在给定的例子中,id是聚簇索引,而idx_age和idx_name是非聚簇索引。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [聚簇索引和非聚簇索引](https://blog.csdn.net/m0_51212267/article/details/124073029)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"]
- *2* *3* [MYSQL性能调优: 对聚簇索引和非聚簇索引的认识](https://blog.csdn.net/chuixue24/article/details/80149270)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文