A network-related or instance-specific error occurred while establishing a connection to SQL Server

Here we go again! You are trying to connect to your freshly installed sql server 2008 R2 express edition using localhost as server name and you are getting this error.


The purpose of this article is to let you know that the fix might be as simple as connecting to the name instance instead of localhost. When you install sql server using the web platform installer tools  , the sql server is installed as a named instance so it is likely to be ComputerName\SQLEXPRESS not localhost.

If you are trying unsure about the server name please use the browse feature of this pop up to locate your server instance or use the command
sqlcmd -L
at the dos prompt.

If you can connect to your named instance but unable to connect to it from a nother comouter on the network you might have some configurations or firewall related issues . In such cases this article below is what you need. 

Reference and Related Links

Open a port windows Firewall



3 comments Write a comment