T-SQL Script that Collects Version, Edition, sp, Authentication and Collation Info

/*
This script collects version, edition, sp, authentication and collation info
from the whole list of instances in the central management servers

Author: Ning Xu
Last Modified Date: 2014-01-21
Applied version: 2000, 2005, 2008, 2008 R2, 2012
*/
select

(case substring(cast(serverproperty('productversion') as varchar), 1, 4)
 when '8.00' then '2000'
 when '9.00' then '2005'
 when '10.0' then '2008'
 when '10.5' then '2008 R2'
 when '11.0' then '2012'
 else 'too old to be paid attention to'
end)
as Sql_version,

serverproperty('edition') as Sql_edition,

serverproperty('productlevel') as Sql_sp,
(
case serverproperty('IsIntegratedSecurityOnly')
when 1 then 'Windows Only'
else 'Mixed' end
)
as Authentication_mode,

serverproperty('collation') as Sql_collation

Advertisements

About Nick Xu

Not a DBA anymore
This entry was posted in T-SQL Script. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s