Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

determine sql server patch level via script

Posted on 2006-03-21
5
Medium Priority
?
1,283 Views
Last Modified: 2012-06-21
folks

via sql server query analyzer how can I using a script determine the version of patch level sql server is on?

roger
0
Comment
Question by:rutgermons
  • 2
  • 2
5 Comments
 
LVL 75

Expert Comment

by:Aneesh Retnakaran
ID: 16254802
Hi rutgermons,
if you are looking for the SP then
select @@version will help you

Cheers!
0
 
LVL 75

Expert Comment

by:Aneesh Retnakaran
ID: 16254808
 No SP
(RTM or Golden) SP1 SP2 SP3 / SP3a SP4 SP5 SP5a
SQL Server 6.0 6.00.121 6.00.124 6.00.139 6.00.151        
SQL Server 6.5
(Hydra) 6.50.201 6.50.213 6.50.240 6.50.258 6.50.281 6.50.415 6.50.416  
SQL Server 7.0
(Sphinx) 7.00.623 7.00.699 7.00.842  7.00.961 7.00.1063    
Use this
http://vyaskn.tripod.com/sqlsps.htm
0
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 16254820
a more precise option:
http://msdn.microsoft.com/library/en-us/tsqlref/ts_sa-ses_3mi1.asp?frame=true
select serverproperty('Edition') as [Edition]
  ,serverproperty('Engine Edition') as [Engine]
  ,serverproperty('Product Version') as [Version]
  ,serverproperty('Product Level') as [Level]
0
 

Author Comment

by:rutgermons
ID: 16254951
it gives me only Edition as an output i.e Enterprize Edition

the rest null,could you pls be as kind as to advise

r
0
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 2000 total points
ID: 16254975
seems the documentation has a bug, there are no spaces in the strings:

select serverproperty('Edition') as [Edition]
  ,serverproperty('EngineEdition') as [Engine]
  ,serverproperty('ProductVersion') as [Version]
  ,serverproperty('ProductLevel') as [Level]
0

Featured Post

[Webinar] Database Backup and Recovery

Does your company store data on premises, off site, in the cloud, or a combination of these? If you answered “yes”, you need a data backup recovery plan that fits each and every platform. Watch now as as Percona teaches us how to build agile data backup recovery plan.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to connect from SSMS v17.x to a SQL Server Integration Services 2016 instance or previous version, you get the error “Connecting to the Integration Services service on the computer failed with the following error: 'The specified service …
This month, Experts Exchange sat down with resident SQL expert, Jim Horn, for an in-depth look into the makings of a successful career in SQL.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Suggested Courses

564 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question