loads of useful information, examples and tutorials pertaining to web development utilizing asp.net, c#, vb, css, xhtml, javascript, sql, xml, ajax and everything else...

 

C-Sharpener.com - Programming is Easy!  Learn Asp.Net & C# in just days, Guaranteed!

An error occured: System.Data.SqlClient.SqlException: A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible.

by naspinski 11/15/2008 2:58:00 PM

One simple solution to this error I often face

More often than not, I think everything should be working when this happens. I check to make sure that connections are allowed, I make sure my sql user has proper permissions and is mapped to the correct database and all that good stuff.

But one thing this fails to tell you is when you do not have sql server login enabled (windows only).

Simply go in to SQL Server Management Studio and right click on your instance and choose properties then click on security in the right side and there you will see your Server Authentication select the proper one and apply.

Now remember, many things can cause this error, this won't fix them all. I just thought I would share as this is not something you may think of when reading that error message.

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

sql

Related posts

Add comment

Name*
E-mail* (Gravatar)
Website
Country   Country flag

Comment* [b][/b] - [i][/i] - [u][/u]- [quote][/quote]




Live preview

1/6/2009 3:24:02 AM