views:

1488

answers:

3

Hello all

I tried to set-up the SQL tables for ASP .net 2.0 membership provider by clicking on ASP.net Configuration under Project.

I have completely uninstalled SQL 2005 Express and installed SQL 2008 Express instead.

It seems like that it can not connect to the database.

Does anybody know how to get this fixed so I can use 2008 instead ?

Thank you. Regards.

A: 

What is your SQL 2008 installation instance called? What does your connection string for the membership provider look like?

As far as I know, there is (or was) a glitch in the SQL Server 2008 Express installation that even if you chose to install as "default" instance, it would still make it a "named instance" called ".\SQLExpress" instead. Could that be the problem?

Marc

marc_s
A: 

As Marc already has pointed out, it could be the problem with the instance name. This is fixed in service pack 1 for SQL Server 2008 Express. For more information and a workaround, see this Microsoft KB article.

Magnus Johansson
A: 

SQL 2005 and 2008 are both configured in a fairly locked down state by default - and this means that SQL won't accept access the database other than through Shared Memory, even with Integrated Security.

You need to enable TCP/IP or Named Pipes for the Client Protocols for the server (as this is how ASP.NET talks to SQL if you've not configured a DSN to use Shared Memory.

I can't remember the exact steps in 2k8, as I've only had to do it once, but in 2k5 you had to open the SQL Server Configuration Manager, select SQL Native Client Configuration, Client Protocols, and enable TCP/IP and Named Pipes - it's a similar process for 2k8 as I recall.

Zhaph - Ben Duguid