SQL express vs SQL developer

S

simonZ

I instal visual studio 2005 without express edition of SQL server. I had
instal developer edition before.

In the web.config it had this connection string:

<add name="LocalSqlServer" connectionString="Data
Source=.\SQLExpress;Integrated Security=True;User
Instance=True;AttachDBFilename=|DataDirectory|aspnetdb.mdf" />

Since my SQL Server 2005 Developer Edition instance is named SQL2005 I
changed this to:

<add name="LocalSqlServer" connectionString="Data
Source=.\SQL2005;Integrated Security=True;User
Instance=True;AttachDBFilename=|DataDirectory|aspnetdb.mdf" />
When trying to run the ASP.NET application, I got this exception:

[SqlException (0x80131904): The user instance login flag is not supported on
this version of SQL Server. The connection will be closed.]

And there is a lot of other problems because I don't have express edition of
SQL server.

What can I do to make things work? Any idea?

regards,S
 
S

simonZ

Hi, KBuser,

thanks for your answer.

What you mean with: "delete this string" ?

ASP.NET I belive needs it's own database for web parts, data components,....
and I should create database mydbfile.mdf.

You can create this database with aspnet_regsql.exe tool (by default it is
created if you install sqlexpress together with visual studio).

In www.connectionstrings.com there is only string for sql express:

"Server=.\SQLExpress;AttachDbFilename=c:\asd\qwe\mydbfile.mdf;Database=dbname;Database=dbname;Trusted_Connection=Yes;"
- or -
"Server=.\SQLExpress;AttachDbFilename=|DataDirectory|mydbfile.mdf;Database=dbname;Trusted_Connection=Yes;"
(use |DataDirectory| when your database file resides in the data
directory)

I can't found it for sql developer edition.

If I just delete it from ASP.NET configuration file, will everything work?

Best regards from Slovenia,
Simon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top