3

I have SQL Server Express installed on my machine as the default instance. "server=.;database=...." I'm now working with a new client where their config files are all checked into the repository. They use a named instance of SQL Server . "server=(local)\SQL2012;database=...."

Is it possible to set up an alias so that I don't have to overwrite anything? What I tried to do using the SQL Server Configuration Tool didn't seem to work, but perhaps I did something wrong.

3

To my knowledge there is no easy way to create a single centralized alias for a SQL server instance.

You can create aliases in the SQL client, but these have to be created on every client machine, so that's not much help. I'm also not sure if your alias can even be formatted as a named instance in that scenario. Actually, you can make an alias appear as a named instance.

In any case you're much better off updating the configs.

Edit

Based on your comment, yes I misunderstood.

In that case a SQL alias is the way to go. You can use SQL Server Configuration Manager if it's installed, but if not you can use the SQL Server Client Network Utility (cliconfig.exe).

If it's not working, one thing to check is the platform. There's a separate version for 32 bit and 64 bit if you're on a 64 bit system:

32bit:

C:\Windows\System32\cliconfig.exe

64bit:

C:\Windows\SysWOW64\cliconfig.exe

Reference

http://www.mssqltips.com/sqlservertip/1620/how-to-setup-and-use-a-sql-server-alias/

| improve this answer | |
  • I think my question was unclear. I'm not trying to centralize anything. I simply want my machine to pretend to have the same SQL server as everybody else -- that is, for (local)\SQL2012 to magically map to the default instance (local). This is a developer workstation so no other clients will be connecting to it. – roufamatic Oct 23 '14 at 5:48
  • Thanks for clarifying, I edited my answer with new information. – briantist Oct 23 '14 at 15:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.