Help: database connection string for different instances?

H

Hongbo

Hi,

I have a test server with Windows 2003 Standard Server. SQL Server 2000
Standard Edition was installed earlier as default instance. My ASP.Net web
site works fine with the connection string
"Server=localhost;UID=sa;PWD=sa;Database=dbSales"
under such circumstance.

Then I installed SQL Server 2005 Standard Edition on the very same machine
with a instance name "sql2005" and "sa2005" as password to "sa" account.
My ASP.Net web site uses
"Server=localhost\sql2005;UID=sa;PWD=sa2005;Database=dbSales"
as connection string to connect the database on SQL Sever 2005. Since
SQL Server 2005 doesn't allow "sa" as password to "sa" account, I have
to use "sa2005" as password.

But I got an error saying "database cannot be accessed" on both SQL
2000 and 2005 when the site tried to access data. Even after I uninstalled SQL
Server 2005, the site still could not access the SQL Server 2000 database with
the above connection string as it did before. The data access worked normally
again only after I uninstalled SQL Server 2000 and reinstalled it.

It seems like SQL Server 2005 override something about SQL Server 2000.

Would you please tell me what I did wrong and how to install correctly both
SQL Server 2000 and SQL Server 2005 on same machine, and what are the
right connection string when two versions of SQL Server present on same machine?

Thank you

hb
 

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,484
Members
44,904
Latest member
HealthyVisionsCBDPrice

Latest Threads

Top