VERY strange database connection problem

B

Buddy Ackerman

I have a web app that I have setup on numerous web servers. I've set one up for a new client at their hosting facility
and cannot get it to connect to their database. I get a "SQL Server does not exist or access denied." error. Well, the
strangeness is that I have a SQL Query tool installed on this server and can connect to the database fine using the
exact same connection parameters that I have specified in my web app. Even more strange is that I have a copy of the
web app on a another web server at another location and I took the connection string from the web server that is not
working and put it on my copy and the copy connects and works fine. Well, it doesn't stop there, on the server that has
the problem I went to create an ODBC datasource just to see if it had any problem. Well, it connected fine but it
wouldn't see the database that I'm trying to connect to (I remind you though that I have connected to this database from
this and other machines with no problems and can query the database). I want to call the hosting facility support desk
to see if there is something funny going on with the database but I'm afraid that they'll just connect with query
analyzer and say there's nothing wrong with the DB and that I need to check my app configuration. I'm not sure where to
go from here, I need some suggestions.

One more thing, when I try to connect through the web app it takes about 30 seconds to return the "does not exist error"
(which is typical when the web server cannot find the DB server on the network). Also, I'm accessing the database
server using it's IP address. I've never see anything this strange before. I'll appreciate any suggestions.


--Buddy
 
K

Kevin Spencer

Hi Buddy,

When you use SQL Query Analyzer, you are connecting to the database as
yourself. You didn't mention whether you're using a Trusted Connection, that
is, using your Windows login rather than a SQL Server account user name and
password. What does your Connection String look like, and what kind of
authentication is being used by the SQL Server (Windows or Mixed)?

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Ambiguity has a certain quality to it.
 
B

Buddy Ackerman

Well, I found the problem. My application is in a subdirectory, actually it was in the root to begin with and moved but
there was still a copy of the old web.config (before i modified it with the new connect string). So, I don't understand
why my application didn't use the web.config setting in the subdirectory. It continued to use the settings in the
web.config in the root of the website.


--Buddy
 

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

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,046
Latest member
Gavizuho

Latest Threads

Top