How to find information about your instance using SERVERPROPERTY.

Here is a way to find out information about your SQL Server instance using TSQL.  You can query  all kinds of properties, for example, what edition are you running, what server is it on, etc.

Using the built in function SERVERPROPERTY, you can query useful information about your SQL Server instance.  You can read more about SERVERPROPERTY here, but below is a query of some common ones that I use.

select @@version, 'version'
union all
select serverproperty('ProductVersion'), 'productversion'
union all
select serverproperty('Edition')  , 'edition'
union all
select serverproperty('ProductLevel'), 'productlevel'
union all
select serverproperty('servername') , 'servername'
union all
select serverproperty('machinename') , 'machinename'


Below you can see some of the versions that I am responsible for.  You can also see there are plenty of servers that need some patching.












There are plenty of things using TSQL that you can learn about your instance.  Do not be afraid and explore!


Leave a Reply

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

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

Facebook photo

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

Connecting to %s