![Share on Facebook Facebook](https://www.sqlserver.info/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/facebook.png)
![Share on Twitter twitter](https://www.sqlserver.info/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/twitter.png)
![Share on Reddit reddit](https://www.sqlserver.info/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/reddit.png)
![Pin it with Pinterest pinterest](https://www.sqlserver.info/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/pinterest.png)
![Share on Linkedin linkedin](https://www.sqlserver.info/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/linkedin.png)
![Share by email mail](https://www.sqlserver.info/wp-content/plugins/social-media-feather/synved-social/image/social/regular/48x48/mail.png)
Here is a super simple query that will get you your current SQL Server version. Enjoy!
SELECT 'SQL Server ' + CASE CAST(SUBSTRING(CAST(SERVERPROPERTY('ProductVersion') AS VARCHAR(100)), 1, CHARINDEX('.', CAST(SERVERPROPERTY('ProductVersion') AS VARCHAR(100)))-1) AS INT) WHEN 8 THEN '2000' WHEN 9 THEN '2005' WHEN 10 THEN '2008' WHEN 11 THEN '2012' WHEN 12 THEN '2014' END + ' ' + CASE CAST(SERVERPROPERTY('ProductLevel') AS VARCHAR(100)) WHEN 'RTM' THEN '' ELSE CAST(SERVERPROPERTY('ProductLevel') AS VARCHAR(100)) + ' ' END + CAST(SERVERPROPERTY('Edition') AS VARCHAR(100)) AS SQLServerVersion