Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_database_setup thread: MSDE Assistance: Login failed for user 'sa'. Reason: Not associated with a trusted SQL Server connection.


Message #1 by "Eric" <eric@d...> on Sat, 20 Apr 2002 04:24:18
Good evening,

I am attempting to Upsize an Access DB to MSDE in preparation for the 
eventual migration to SQL Server.

In attempting to access the DB via ASP I am receiving the following error:

Microsoft OLE DB Provider for SQL Server error '80004005'

Login failed for user 'sa'. Reason: Not associated with a trusted SQL 
Server connection.

/7275957373/db/datastore.asp, line 37

My connection object is the following:

objConn.Open 	"Provider=SQLOLEDB;Persist Security Info=False;" & _
		"User ID=sa;Initial Catalog=subrep;" & _
		"Initial File Name = C:\Program Files\Microsoft SQL 
Server\MSSQL\Data\subrepSQL.mdf"


Can someone please tell me how I would go about resolving this problem? 

I am running on a WinXP machine and the DB is located on a W2K Server 
running IIS across a Local Network.

Thanks much for any and all assistance.

Regards,
Eric
Message #2 by "Eric Levine" <eric@d...> on Sat, 20 Apr 2002 09:35:02 -0400
FOLLOW UP:

I have tried two different connection strings, both to no avail.  One
with User ID and the other with Integrated Security.  Please see the
code and the errors below.  Any help would be appreciated.

objConn.Open "Provider=sqloledb;" & _
           "Data Source=Flipper;" & _
           "Initial Catalog=subrepSQL;" & _
           "User ID=sa;" & _
           "Password=;"

Microsoft OLE DB Provider for SQL Server error '80004005'
Login failed for user 'sa'. Reason: Not associated with a trusted SQL
Server connection.

objConn.Open "Provider=sqloledb;" & _
           "Data Source=Flipper;" & _
           "Initial Catalog=subrepSQL;" & _
           "Integrated Security=SSPI;" 

Microsoft OLE DB Provider for SQL Server error '80040e4d'
Login failed for user 'DEV\IUSR_FLIPPER'.


Regards,
Eric

-----Original Message-----
From: Eric [mailto:eric@d...] 
Sent: Saturday, April 20, 2002 4:24 AM
To: ASP Database Setup
Subject: [asp_database_setup] MSDE Assistance: Login failed for user
'sa'. Reason: Not associated with a trusted SQL Server connection.

Good evening,

I am attempting to Upsize an Access DB to MSDE in preparation for the 
eventual migration to SQL Server.

In attempting to access the DB via ASP I am receiving the following
error:

Microsoft OLE DB Provider for SQL Server error '80004005'

Login failed for user 'sa'. Reason: Not associated with a trusted SQL 
Server connection.

/7275957373/db/datastore.asp, line 37

My connection object is the following:

objConn.Open 	"Provider=SQLOLEDB;Persist Security Info=False;" & _
		"User ID=sa;Initial Catalog=subrep;" & _
		"Initial File Name = C:\Program Files\Microsoft SQL 
Server\MSSQL\Data\subrepSQL.mdf"


Can someone please tell me how I would go about resolving this problem? 

I am running on a WinXP machine and the DB is located on a W2K Server 
running IIS across a Local Network.

Thanks much for any and all assistance.

Regards,
Eric
eric@d...
%%email.unsub%%




Message #3 by "Ken Schaefer" <ken@a...> on Mon, 22 Apr 2002 11:38:59 +1000
a) If the database is using NT Integrated Security (which is seems to be)
then you can't use a userID/Password combination in your connection string.
Instead, the user account must be permitted to login to the database. In
this case, the anonymous internet user account (IUSR_<machinename>)

b) You need to permit the account in question to login to the database
server. What management tools do you have available? Enterprise Manager?
Query Analyser?

Cheers
Ken

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "Eric Levine" <eric@d...>
Subject: [asp_database_setup] RE: MSDE Assistance: Login failed for user
'sa'. Reason: Not associated with a trusted SQL Server connection.


: FOLLOW UP:
:
: I have tried two different connection strings, both to no avail.  One
: with User ID and the other with Integrated Security.  Please see the
: code and the errors below.  Any help would be appreciated.
:
: objConn.Open "Provider=sqloledb;" & _
:            "Data Source=Flipper;" & _
:            "Initial Catalog=subrepSQL;" & _
:            "User ID=sa;" & _
:            "Password=;"
:
: Microsoft OLE DB Provider for SQL Server error '80004005'
: Login failed for user 'sa'. Reason: Not associated with a trusted SQL
: Server connection.
:
: objConn.Open "Provider=sqloledb;" & _
:            "Data Source=Flipper;" & _
:            "Initial Catalog=subrepSQL;" & _
:            "Integrated Security=SSPI;"
:
: Microsoft OLE DB Provider for SQL Server error '80040e4d'
: Login failed for user 'DEV\IUSR_FLIPPER'.
:

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Message #4 by "Eric Levine" <eric@d...> on Mon, 22 Apr 2002 09:12:22 -0400
Thank you to all who responded to my question.

I ended up downloading the trial verson of SQL Server 2000 to gain
access to the Enterprise Manager.  With this tool now in my possession I
was able to make the necessary edits to the login to once again gain
access to the DB.

Leave it to Microsoft to put out a product that is a "step-up" from
Access only to cripple it by regulating the number of concurrent users
and by omitted a key tool to administer the database.

Thanks again.


-----Original Message-----
From: Ken Schaefer [mailto:ken@a...] 
Sent: Sunday, April 21, 2002 9:39 PM
To: ASP Database Setup
Subject: [asp_database_setup] RE: MSDE Assistance: Login failed for user
'sa'. Reason: Not associated with a trusted SQL Server connection.

a) If the database is using NT Integrated Security (which is seems to
be)
then you can't use a userID/Password combination in your connection
string.
Instead, the user account must be permitted to login to the database. In
this case, the anonymous internet user account (IUSR_<machinename>)

b) You need to permit the account in question to login to the database
server. What management tools do you have available? Enterprise Manager?
Query Analyser?

Cheers
Ken

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "Eric Levine" <eric@d...>
Subject: [asp_database_setup] RE: MSDE Assistance: Login failed for user
'sa'. Reason: Not associated with a trusted SQL Server connection.


: FOLLOW UP:
:
: I have tried two different connection strings, both to no avail.  One
: with User ID and the other with Integrated Security.  Please see the
: code and the errors below.  Any help would be appreciated.
:
: objConn.Open "Provider=sqloledb;" & _
:            "Data Source=Flipper;" & _
:            "Initial Catalog=subrepSQL;" & _
:            "User ID=sa;" & _
:            "Password=;"
:
: Microsoft OLE DB Provider for SQL Server error '80004005'
: Login failed for user 'sa'. Reason: Not associated with a trusted SQL
: Server connection.
:
: objConn.Open "Provider=sqloledb;" & _
:            "Data Source=Flipper;" & _
:            "Initial Catalog=subrepSQL;" & _
:            "Integrated Security=SSPI;"
:
: Microsoft OLE DB Provider for SQL Server error '80040e4d'
: Login failed for user 'DEV\IUSR_FLIPPER'.
:

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


eric@d...
%%email.unsub%%




Message #5 by "Ken Schaefer" <ken@a...> on Tue, 23 Apr 2002 18:07:39 +1000
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "Eric Levine" <eric@d...>
Subject: [asp_database_setup] RE: MSDE Assistance: Login failed for user
'sa'. Reason: Not associated with a trusted SQL Server connection.

...
: Leave it to Microsoft to put out a product that is a "step-up" from
: Access only to cripple it by regulating the number of concurrent users
: and by omitted a key tool to administer the database.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Exactly how much did you pay for MSDE...?

If you want something that is "uncrippled" and contains nice admin tools
fork out the money for SQL Server.

Cheers
Ken


  Return to Index