To determine which version of SQL Server 2000/2005 is running, connect to SQL Server 2000/2005 by using Query Analyzer, and then run the following code:
SELECT SERVERPROPERTY('productversion'), SERVERPROPERTY ('productlevel'), SERVERPROPERTY ('edition')
The results are:
The product version (for example, 8.00.534).
The product level (for example, “RTM” or “SP2”).
The edition (for example, “Standard Edition”).
For example, the result looks similar to:
8.00.534 RTM Standard Edition
Reference : Pinal Dave (https://blog.sqlauthority.com)
2 Comments. Leave new
This is fine but it does not provide the friendly 2000, 2005 etc version info. Any ideas on reporting a user friendly version number?
Why can there be a difference between @@version and serverproperty command? Which is more reliable…
For e.g @@version is stating SP2 and productlevel is stating RTM