Monday, February 13, 2012

App_Data new DB fails

Hello,

I'm trying to create a new SQL Express database in VWD, and I get the error: Failed to generate a user instance of SQL Server due to a failure in starting the process for the user instance. The connection will be closed.

What is this error all about? I don't understand it.

Thanks.

The db when added in VS has no owner and is somehow bound to the profile. So many things can go wrong with that, so instead of guessing, wipe it out and let the IDE recreate it.

This blog saved me days of heartache. Unfortunately, I still wasted time till I came across it.

http://www.sqljunkies.com/WebLog/ktegels/archive/2005/11/15/17401.aspx

1. Disconnect all dbs, close down the IDE, close down SSMS(if any) on your machine.
2. Stop all services and processes related to sql server.
3. Rename(safer than deleting) the whole folder:
c:\Documents and Settings\[user]\Local Settings\Application Data\Microsoft\Microsoft SQL Server Data\SQLEXPRESS

4.restart the IDE/SSE.
5. this song-n-dance may not work the first time. Try more than once.

I am really disappointed at the flaky architecture of SSE and have stopped using it since.

HTH!

No comments:

Post a Comment