I have developer edition from SQL Server 2008, but now I have a piece of software with a hardcoded connection string:
Data Source=.\SQLEXPRESS;Initial Catalog=db;User Id=sa;Password=1234;
Now I tried adding an Alias in the configuration tool to SQLEXPRESS, but it just doesn't want to use this new alias.
I enabled TCP/IP and restarted the service.
Best Answer
Follow these steps to add an alias:
New Alias...
.\SQLEXPRESS
for the Alias Name..
for the server name (that's equivalent tolocalhost
).Changing the HOSTS file to include a setting for SQLEXPRESS will only redirect DNS lookups for a machine called SQLEXPRESS to the specified IP address. That will not cause
.\SQLEXPRESS
to resolve to the localhost SQL instance.