|
-
September 8th, 2008, 02:19 AM
#1
I have 2 SQL Server instances and I have a problem!
I have 2 SQL Server Instances, SQL Server 2000 and SQL Server 2005 -both are developer editions-.
If I have the Northwind database attached to both SQL Server Instances and I need to access Northwind in a specific instance. What should I do?
Take into consideration that I'm using Visual Studio 2005 Team Edition and C#.
So,
I need to know how to access the Northwind database in a specific instance like SQL Server 2005.
What will my connection string be?
-
September 8th, 2008, 07:45 AM
#2
Re: I have 2 SQL Server instances and I have a problem!
-
September 8th, 2008, 07:51 AM
#3
Re: I have 2 SQL Server instances and I have a problem!
Thanks very much
But, that wouldn't help
I found in www.connectionstring.com that:
Server=myServerName\theInstanceName;Database=myDataBase;Trusted_Connection=True;
I know that all
But, How can I get {theInstanceName} I tried that many and many times.
But, Actually, I failed
-
September 8th, 2008, 11:07 AM
#4
Re: I have 2 SQL Server instances and I have a problem!
so you don't already know the instance names? If not, you can get them from the registry:
\\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\Instance Names\SQL
-
September 8th, 2008, 07:21 PM
#5
Re: I have 2 SQL Server instances and I have a problem!
You can also look at the list of services in the Administrative Tools - the instance names will be listed as part of the service (ie, MSSQL$SRV1, etc)
-
September 9th, 2008, 04:35 PM
#6
Re: I have 2 SQL Server instances and I have a problem!
Well i know a Sure way to Find an instance, but its a long way, get a SQL2005 installtion CD, there is a point where it ask you to install the Intance and there is a button that says "Installed Instances" if you click there if wil show you the instances for that Computer, but in most of the case the name of the instance is the name of the Computer. but now can i see the name of your Computer, if your Computer name has some "-", then when you install SQL it will create a default instance and it will remove the special character.
Hope it Helps
-
September 10th, 2008, 08:15 AM
#7
Re: I have 2 SQL Server instances and I have a problem!
 Originally Posted by vuyiswam
Well i know a Sure way to Find an instance, but its a long way, get a SQL2005 installtion CD, there is a point where it ask you to install the Intance and there is a button that says "Installed Instances" if you click there if wil show you the instances for that Computer, but in most of the case the name of the instance is the name of the Computer. but now can i see the name of your Computer, if your Computer name has some "-", then when you install SQL it will create a default instance and it will remove the special character.
Hope it Helps
the default instance name for SQL Server are MSSQLSERVER and for SQL Express it's SQLEXPRESS
-
September 11th, 2008, 02:34 AM
#8
Re: I have 2 SQL Server instances and I have a problem!
Thank you very much I tried that and it works so fine.
Thanks very much for every one.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|