Thursday, July 18, 2013

SQL Server 2012: Find SQL Server Collation


Description

How to retrieve collation information for SQL Server 2012.


Solution

During the set up of SQL Server 2012, the default collations are as follows (as shown below):


Database Engine:  SQL_Latin1_General_CP1_CI_AS

Analysis Services:  Latin1_General_CI_AS





To retrieve the collation of the Database Engine for an existing SQL Server instance:

SELECT CONVERT (varchar, SERVERPROPERTY('collation'));

 
To retrieve  the collation of databases attached to the SQL Server instance:

SELECT name, collation_name FROM sys.databases;

(MSDN, 2012)



Reference

MSDN (2012).  View Collation Information.  Retrieved July 18, 2013 from http://msdn.microsoft.com/en-us/library/hh230914.aspx

No comments:

Post a Comment