Re: Connection Error - please help

From: Steven Bras (sbras(delete)_at_cablespeed.com)
Date: 08/24/04


Date: Mon, 23 Aug 2004 17:25:11 -0700

There are many causes for that error message; but given the fact that you've
connected successfully using your DSN, it's most likely that the DSN is set
to use Windows authentication, and that the Windows account used by IIS is
not permitted access to the SQL Server database. This often happens if the
SQL Server database resides on a server different from IIS. It works when
testing from the ODBC Administrator because the account used for
authentication is the logged-in user's account (presumably yours).

This can be resolved by using a SQL login instead of a Windows account.
However, if you wish to authenticate using the Windows account, you'll have
to either create a domain account with permission to the database, and set
that account as your anonymous user account in IIS, or create a duplicate
anonymous account on the SQL Server machine (same name, same password) and
grant it access to the database. These anonymous accounts are, by default,
in the format "IUSR_machinename" and "IWAM_machinename".

Bear in mind that you're not using ODBC or the DSN when using the SQL OLEDB
Provider.

It could be a number of other things too. See the following Knowledge Base
article; it may be of help (to find these, I just searched
http://support.microsoft.com for "SQL Server Does Not Exist"):

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

Good luck!

"davin" <davin@discussions.microsoft.com> wrote in message
news:61096F9A-C92A-4CDA-92D4-8E95B3674B3D@microsoft.com...
> I'm setting up a development environment on XP Pro. I'm working with
classic
> ASP. IIS is working great, but when trying to connect to my SQL Server
> Database, I get:
>
> Microsoft OLE DB Provider for SQL Server (0x80004005)
> [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access
> denied.
>
> I've checked and re-checked both the name of the database and server, plus
> everything looks configured correctly in Enterprise Manager (SQL server
and
> Windows is checked).
>
> In ODBC, after I configure my System DSN, I test it and it connects
> correctly. But this dang error persists. I'm at my wits end with it all,
> can you help?
>
> Any comments would be very very appreciated.
>
> Thank you.
>
>



Relevant Pages

  • RE: Problems with WebParts
    ... to a database called aspnetdb. ... > The connection string specifies a local SQL Server Express instance using a ... > server account must have read and write access to the applications directory. ... > This is necessary because the web server account will automatically create ...
    (microsoft.public.dotnet.framework.aspnet)
  • RE: DTS Package fails when Scheduled
    ... Apparently I was unable to pass on the database password when runninig the ... Make sure SQL Server Agent account has the correct rights/permissions. ... scheduled job under this context, I still received the error, even though I ...
    (microsoft.public.sqlserver.dts)
  • Problems with WebParts
    ... The connection string specifies a local SQL Server Express instance using a ... database location within the applications App_Data directory. ... server account must have read and write access to the applications directory. ... logged-in user needs the dbcreator privilege in the appropriate SQL Server ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: sa password was inadvertently changed. With a kicker...
    ... Use some other account that the client has (any domain admin should have ... Did around there install package, and see if the sql script that changed ... Put the database files back where they should ... > I have a SQL Server 7 Standard edition server running in a ...
    (microsoft.public.sqlserver.security)
  • Re: does sql user need to be an admin?
    ... User accounts need to be granted access to SQL Server in order to ... file permissions do not control database access. ... This account is a member of the ... Grant a Windows account access to SQL Server: ...
    (microsoft.public.sqlserver.security)