What Service Pack is That

A commonly asked question is how to identify the SQL Server Service Pack that is installed. It is possible to identify what version is being run based on the build number returned from the @@VERSION configuration function.

ie.
SELECT @@VERSION
Retruns:
Microsoft SQL Server  2000 – 8.00.818 (Intel X86)
May 31 2003 16:08:15
Copyright (c) 1988-2003 Microsoft Corporation
Standard Edition on Windows NT 5.2 (Build 3790: )

The following KB article details how to do determine the Service Pack level from the build number http://support.microsoft.com/default.aspx?scid=kb;en-us;q321185 .

However one of the often overlooked function is the ProductLevel property name of the SERVERPROPERY function.

SELECT SERVERPROPERTY(‘ProductLevel’)
Returns:
——–
SP3
(1 row(s) affected)