Monday, September 9, 2024

How do I check the SQL Server version and edition?

 Use the following query to get the SQL Server version and edition:

SELECT SERVERPROPERTY('ProductVersion') AS Version, 

 SERVERPROPERTY('ProductLevel') AS ProductLevel,

 SERVERPROPERTY('Edition') AS Edition;

This returns the version, product level (e.g., RTM, SP1), and edition of the SQL Server instance.