:::: MENU ::::

Get name of your SQL Server instance

  • Jun 04 / 2009
  • 0
DBA Interview questions, dbDigger, System Functions

Get name of your SQL Server instance

There may be a requirement to get exact name of any SQL Server instance. There are some ways to accomplish this task. Any of these ways can be usedn>

SELECT @@servername

Or system table sys.sysservers or sysservers may be queried to get the name of instance. However this table is contains one row for each server that an instance of SQL Server can access. So there may be records for linked servers in it.

Consult us to explore the Databases. Contact us