如何确定SQL Server实例是否区分大小写 [英] How to determine if an instance of SQL Server is case sensitive or not

查看:158
本文介绍了如何确定SQL Server实例是否区分大小写的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何确定SQL Server 2005实例是否允许区分大小写的数据库?

How can I find out if an instance of SQL Server 2005 allows case sensitive databases or not?

按大小写区分,是指对象中的对象区分大小写数据库,即以下两个语句不相等:

By case sensitive, I mean case sensitivity of the objects in the database, i.e. the following two statements are not equivalent:

SELECT * FROM TABLE
SELECT * FROM table

我已经查看了服务器的属性页(在Management Studio中),但看不到。

I've looked in the property pages of the server (in Management Studio) but I couldn't see it.

推荐答案

SELECT DATABASEPROPERTYEX('DatabaseNameHere', 'Collation') SQLCollation;

返回 SQL_Latin1_General_CP1_CI_AS,CI表示不区分大小写

Returns "SQL_Latin1_General_CP1_CI_AS", the CI is what indicates case insensitivity

这篇关于如何确定SQL Server实例是否区分大小写的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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