How to Create and Delete an Alias in SQL Server

An alias (an alternate name for a SQL Server instance) can be created and deleted from SQL Server Configuration Manager or SQL Server Client Network Utility.
If you move a database used by an application to a new server and you can't change the specified database connection in the application, you can use an alias and keep the application configuration unchanged.

SQL Server Configuration Manager:

In SQL Server Configuration Manager -> expand the SQL Native Client Configuration folder -> right-click on Aliases -> choose New Alias:

sql server configuration manager create new alias

Enter 'Alias Name' , Port number, protocol, and the server that the alias points to (in this example it is local server's default instance, for a named instance append the instance name):

sql server configuration manager create new alias

Now you can connect to te SQL Server instance using the new created alias:

connecting to new alias

To delete an alias, in SQL Server Configuration Manager -> expand the SQL Native Client Configuration folder -> expand Aliases -> right click on Alias -> choose Delete:

configuration manager delete an alias

SQL Server Client Network Utility (is shipped with Windows and can be found at C:\WINDOWS\system32\cliconfg.exe):

click Start -> Run -> cliconfg.exe -> click on the Alias tab:

client network utility create new alias

You can see aliases created in SQL Server Configuration Manager here, and aliases created in SQL Server Client Network Utility are visible in SQL Server Configuration Manager.

New aliases can be created using the 'Add' button on the right, and existing aliases can be deleted using the 'Remove' button.

If the post helped you, please share it:
Pin It

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">