[Last Call] Learn how to a build a cloud-first strategyRegister Now


Error 26 When Trying to Connect / Create a Database

Posted on 2007-10-03
Medium Priority
Last Modified: 2013-11-27
Hi all,

I am a new user to Visual Studio.  I reached my limits with Access and I'm trying to move on.  

Being new to this I need some help getting off the ground.  When I try to create a new SQL server Database I keep getting an Error: An error has occurred while establishing a connection to the server.....(provider: SQL Network Interfaces, error 26 - Error Locating Server / Instance Specified).

I'm trying to use my computer as the host for right now to learn how to use the Studio.  I've tried looking online for a solution to this, but the solutions are a little over my head since I've never used this.  

Is this the right way to create a new database or is there another way?

I've updated my my Remote Connection to use TCP/IP only.

Any help getting started would be appreciated.
Question by:42na
  • 3
LVL 16

Assisted Solution

SQL_SERVER_DBA earned 1000 total points
ID: 20008842
In a word, the reason that we get this error message is the client stack could not receive SSRP response UDP packet from SQL Browser. It's easy to isolate the issue. Here are the steps:
1) Make sure your server name is correct, e.g., no typo on the name.
2) Make sure your instance name is correct and there is actually such an instance on your target machine.
3) Make sure the server machine is reachable, e.g, DNS can be resolve correctly, you are able to ping the server (not always true).
4) Make sure SQL Browser service is running on the server.
5) If firewall is enabled on the server, you need to put sqlbrowser.exe and/or UDP port 1434 into exception.

Once you are done the steps, you should not see this error message anymore. You may still fail to connect your SQL server, but error message should be different and you have a different issue now.

Author Comment

ID: 20009832
Okay now I'm getting error 25 Connection String Not Valid.  I know this isn't the same problem but if this is a quick answer I'd appreciate it without a repost.

Author Comment

ID: 20009970
Hi Again,  I'm guessing my Server name is incorrect.  I can access it in VB Studio Manager and create databases.  When I test the connection in VB SM it works fine.  When I try to connect to that databaser in VB Studio it gives me that error, even when I go and select the mdf file I'm trying to connect to.

My Server name is SDN-046682.  Is this a valid name?

Also, the connection wizard keeps defaulting to SQLExpress.  I use to have that installed on my computer.  I thought I totally uninstalled that app.  I now have the full version of SQL Server.  Could this be one of the problems?

Thanks again for your help.  If you'd like me to post this in a new post please let me know.

Accepted Solution

assyst earned 1000 total points
ID: 20010570
I guess that it is tring to connect to SQLExpress. Go to SQL Server Configuration Manager and stop the SQLExpress DB engine [SQL Server (SQLExpress). Also check whether you have any instance name in bracket after the name, for eg: SQL Server(Dev05). If you have so, then the servername should be given as <ComputerName>\Dev05.

Have a nice day.


Author Comment

ID: 20044970
The problem was that the SQLExpress did not get fully deleted off my computer.  Thanks for your help.

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
An alternative to the "For XML" way of pivoting and concatenating result sets into strings, and an easy introduction to "common table expressions" (CTEs). Being someone who is always looking for alternatives to "work your data", I came across this …
Via a live example, show how to shrink a transaction log file down to a reasonable size.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.
Suggested Courses

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question