Sql Server索引(群集/非群集) [英] Sql Server Index (Clustered/ Non Clustered)

查看:97
本文介绍了Sql Server索引(群集/非群集)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





我对sql server索引有些困惑。我在google上搜索了这个主题并浏览了多个博客,但对我来说还不清楚。



我的问题是,我可以创建基于多列的集群索引吗?并且这些列不是主键或唯一键。

解决方案

您好,



检查这个.. 。 sql server中的集群索引和非集群索引之间的区别 [ ^ ]



希望这会对你有所帮助。



干杯


如果您为之类的任何列创建主键,则studentId 将为 studentId创建一个群集列。

一个表只能有一个主键 Clustered Inde X

Hi,

I have some confusion regarding sql server indexing. I have searched in google this topic and gone through multiple blogs but still it's not clear for me.

My question is, can i create a cluster index based on multiple column and these columns are not a primary or unique key.

解决方案

Hi,

Check this...Difference between clustered and non clustered index in sql server[^]

Hope this will help you.

Cheers


If you created a Primary key for any column like studentId will create a clustered for studentId Column .
A table can have only one Primary key and Clustered Index.


这篇关于Sql Server索引(群集/非群集)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆