Follow sqlserver-dba.com

Subscribe to RSS feed  Follow @jackvamvas - Twitter

*Use the Comments section for questions

SQLServer-DBA.com Links

Dba_db2_button

dba-ninja.com

SQL Server DBA Jobs

How to find the SQL Server service pack is installed

09 June,2015 by Tom Collins

Question: How can I check programmatically the SQL Server  service pack?  I’d like to check all SQL Servers , create a report detailing the service pack levels.

Answer:   The SERVERPROPERTY('productlevel')  returns the service pack level.   To make a useful decision I like to present some extra information.

I include Server Name, Build Level, SQL Server Edition, Server or Default Collation,Instance Name, LCID

SELECT  
    SERVERPROPERTY('servername') as 'Server Name',
    SERVERPROPERTY('productversion') as 'Build Level', 
    SERVERPROPERTY('productlevel') as 'Patch Level',  
    SERVERPROPERTY('edition') as 'SQL Server Edition',
    SERVERPROPERTY('buildclrversion') as 'CLR version',
    SERVERPROPERTY('collation') as 'Server Collation',
    SERVERPROPERTY('instancename') as 'Instance Name',
    SERVERPROPERTY('lcid') as 'LCID'
    


Read More on SQL Server meta information

SQL Server Version with Powershell - SQL Server DBA

SQL Server – Get SQL Server Version - SQL Server DBA

How to find SQL License type - SQL Server DBA


Author: Tom Collins (http://www.sqlserver-dba.com)


Share:

Verify your Comment

Previewing your Comment

This is only a preview. Your comment has not yet been posted.

Working...
Your comment could not be posted. Error type:
Your comment has been posted. Post another comment

The letters and numbers you entered did not match the image. Please try again.

As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

Having trouble reading this image? View an alternate.

Working...

Post a comment on How to find the SQL Server service pack is installed


sqlserver-dba.com | SQL Server Performance Tuning | SQL Server DBA:Everything | FAQ | Contact|Copyright & Disclaimer