Howto find out which SQL Server Version is running

-- the old way
SELECT @@VERSION
-- better way, tells you the Service pack level, too
SELECT SERVERPROPERTY('productversion')
AS ProductVersion,
SERVERPROPERTY('productlevel')
AS ProductLevel,
SERVERPROPERTY('edition')
AS Edition
-- or 
PRINT 'ProductVersion: '
+ CAST(SERVERPROPERTY('productversion')
AS VARCHAR(255))
PRINT 'ProductLevel  : '
+ CAST(SERVERPROPERTY ('productlevel')
AS VARCHAR(255))
PRINT 'Edition       : '
+ CAST(SERVERPROPERTY ('edition')
AS VARCHAR(255))