Error: SQL Server does not exist or access denied in ASP Application

S

Simone

Hi!
I'm an Italian Boy,
Excuse Me for my incorrect language.
I have a Server with Windows Server 2003 Enterprise Architect and SQL Server
2000 Enterprise.

I'm developing an ASP Web Application, but when i try to connect to my SQL
Server Database by this connectionstring

"data source=MYSERVER;initial catalog=MYDATABASE;password=MYPWD;user id=Sa"

I receive th error : 'SQL Server does not exist or access denied'.

I' have checked the condition in this Kb :

http://support.microsoft.com/default.aspx?scid=kb;en-us;328306

and this Kb
http://support.microsoft.com/default.aspx?scid=kb;en-us;315159&Product=aspnet

but i cannot resolve my problem.

Thanks!
Simone
 
A

Andy Fish

Simone said:
Hi!
I'm an Italian Boy,
Excuse Me for my incorrect language.
I have a Server with Windows Server 2003 Enterprise Architect and SQL
Server
2000 Enterprise.

I'm developing an ASP Web Application, but when i try to connect to my SQL
Server Database by this connectionstring

"data source=MYSERVER;initial catalog=MYDATABASE;password=MYPWD;user
id=Sa"

I receive th error : 'SQL Server does not exist or access denied'.

I'm not an expert on these things but I would use "server=MYSERVER" or, if
the database is on the same machine, leave out that bit altogether

make sure SQL server is running and listening on port 1433 and
 
S

Simone

I develope in a Remote Machine,
SQL server is running and listening on port 1433.

Any ideas?

thanks.

Simone
 
S

Simone

Ok,

but my connectionstring is Correct because if I use this connectionstring in
a vb.Net Application, it run!

thanks,

Simone
 
K

Kevin Spencer

but my connectionstring is Correct because if I use this connectionstring
in
a vb.Net Application, it run!

If I were to tell you that my carbeurator was correct because it works in my
Volkswagon, but when I put it in my Porsche, it doesn't run, would I be
correct?

A VB.Net executable is not an ASP.Net web application. For one thing, they
run under different user accounts. Hence, the "access denied" part of the
error message.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Neither a follower nor a lender be.
 
B

Bob Barrows [MVP]

Simone said:
I have tryed all solution in www.connectionstrings.com, but it
doesn't work
We can't help you if you don't:
1. SHOW us what you tried
2. Describe your symptoms without using the words "doesn't work" This means:
detailed error messages (or the lack thereof), perceived behavior vs.
expected behavior, etc.

Are you tying to use trusted connection? If so, are you aware of what
account is being used by ASP.Net to run your code? That there is a
possibility that it is not the user loading the page? See if these KB
articles are relevant:
http://support.microsoft.com/default.aspx?scid=kb;en-us;Q315159
http://support.microsoft.com/kb/316989
http://support.microsoft.com/default.aspx?scid=kb;en-us;Q315158

Bob Barrows
 
G

Guest

Check your network protocols. By default, SQL Server uses named pipes, while
the app itself will attempt a TCP/IP connection. If you can connect with SQL
Server tools, like Query Analyzer, this is most likely the problem (at least
when you are using SQL security). The same is true for most Windows apps and
Console apps, which will try named pipes first.

If this is your problem, add the TCP/IP network protocol to the SQL Server
and you will be up and running again. You do this through the Server Network
Utility.


---

Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

***************************
Think Outside the Box!
***************************
 
G

Guest

More likely it is a protocol problem. Windows apps attempt named pipes first.
ASP.NET apps are more likely to try TCP/IP first, which is not loaded in all
SQL Server installations.

---

Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

***************************
Think Outside the Box!
***************************
 
A

Andy Fish

hmm, that's pretty strange

maybe some firewall or antivirus program realised you didn't have SP3 and
blocked the traffic in case of slammer vulnerability?
 

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,766
Messages
2,569,569
Members
45,043
Latest member
CannalabsCBDReview

Latest Threads

Top