 |
| ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum. |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|

July 23rd, 2007, 10:39 AM
|
|
Registered User
|
|
Join Date: Jul 2007
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
SQL Server 2000 connectivity issue
Hi,
My application has accessing data from a remote database server .
My connection string is defined in web.config as follows
<appSettings>
<add key="ConnectionString" value="data source=DEVSVR;initial catalog=DEInsdata;user id=sa;"></add>
</appSettings>
Whenever I am running the application from VS.NET 2005 it runs fine but when I run application from IE the application never run and there is a message sql server 2005 does not allow remote connections and the most surprising thing is that my database is SQl SERVER 2000 so I am really confused with this error message.
Kindly help me
|
|

July 24th, 2007, 05:38 AM
|
|
Registered User
|
|
Join Date: Jul 2007
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Indeed a nice article!
One small query here
You have shown in query string for sql server 2005 will be (4 SQL Authentication)
<connectionStrings>
<add name="BugBase"
connectionString="Data Source=.\SQL2005; Initial Catalog=BugBase;
User ID=MyWebsiteUser;password=Pa$w0rD"
providerName="System.Data.SqlClient" />
</connectionStrings>
while my application's (it is using SQL SERVER 2000) connection string definedin web.config file is
<appSettings>
<add key="ConnectionString" value="data source=DEVSVR;initial catalog=DEInsdata;user id=sa;"></add>
</appSettings>
Do you think I need to mention data source=DEVSVR\SQL2000 instead of data source=DEVSVR as u have mentioned SQL2005 in ur connection string
|
|

July 24th, 2007, 06:16 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
No, that's just an example. it all depends on how your SQL Server instance is called. The default instance is unnamed, so if you installed SQL Server 2000 on a box call DevMachine you can access it like DevMachine. However, if you installed a SQL Server *instance* called WhatEver, you access the machine as DevMachine\WhatEver.
As you can see, you need to include the instance name in the connection string if there is an instance name.
For more info: www.connectionstrings.com
Cheers,
Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.
|
|

July 24th, 2007, 07:26 AM
|
|
Registered User
|
|
Join Date: Jul 2007
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
thnx 4 ur reply.
You know what ... in the database server there was not an instance of SQL Server 2005 though that's there in my development server.
|
|

July 24th, 2007, 07:57 AM
|
|
Registered User
|
|
Join Date: Jul 2007
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
The problem has solved in very crude fashion. We have installed Sql2000 in a fresh machine and put all the tables, Sp's from our database server to this new machine. Now there is no problem. Still confused why the problem was there
|
|

July 24th, 2007, 03:10 PM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
There could be many many reasons. Your SQL instance may have been named differently, maybe the old server didn't support SQL Server authentication, maybe you had a firewall turned on, disabled network protocols and I could go on an on.
Bottom line: impossible to tell without seeing the actual machine....
Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.
|
|

July 25th, 2007, 01:25 AM
|
|
Registered User
|
|
Join Date: Jul 2007
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Thnx for ur reply.
I've two more things to know:
1)In what location of development server and database server I can check firewall settings?
2)In what location of development server and database server I can check whether network protocols are disable or not?
|
|

July 25th, 2007, 09:17 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Quote:
|
quote:1)In what location of development server and database server I can check firewall settings?
|
On the firewall..... ;) But also on the Windows Servers involved. Recent versions of Windows have a built-in firewall.
Quote:
|
quote:2)In what location of development server and database server I can check whether network protocols are disable or not?
|
On the SQL Server 2000 box. Look in the relevant Start Menu for an item called "Client Network Utility"
Cheers,
Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.
|
|
 |