SQL Server/T-SQL Tutorial/System Settings/SERVERNAME
Returning the Current SQL Server Instance Name and SQL Server Version
4>
5> SELECT @@SERVERNAME ServerName
6> GO
ServerName
------------------------------------------------------------------------------------------------------------------------
--------
BCE67B1242DE45A\SQLEXPRESS
(1 rows affected)