You can easily, with just a single query of 4-5 words, fetch your Machine name and SQL Server Instance name. Machine name is the one which can be find by right clicking your Computer and then selecting Properties from the right click context menu and SQL Server Instance name is the one to which you are currently logged in, in your SQL Server. Actually you can have multiple Instances of SQL Server and every instance can have a number of different Logins. These can be setup during the installation of the product only and if later you want to add instances to SQL Server, you have to install the instance separately using the CD. The instance name can be found on the login screen of SQL Server.
Instructions:
- Using @@SERVERNAME function
- Using SERVERPROPERTY function