Wrox Programmer Forums
Go Back   Wrox Programmer Forums > SQL Server > SQL Server 2000 > SQL Server 2000
|
SQL Server 2000 General discussion of Microsoft SQL Server -- for topics that don't fit in one of the more specific SQL Server forums. version 2000 only. There's a new forum for SQL Server 2005.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server 2000 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
 
Old August 20th, 2003, 07:29 PM
Authorized User
 
Join Date: Jun 2003
Posts: 61
Thanks: 0
Thanked 0 Times in 0 Posts
Default not associated with a trusted SQL Server Connectio

Hey guyz am having problems accessing the database from a VB6 program and instead getting the error below.

Run-time error '-2147217843 (80040e4d)
[Microsoft][ODBC SQL Server Driver][SQL Server][Login failed for user '[null]'. Reason:
not associated with a trusted SQL Server Connection.


the client is using Windows NT Authentication

and am using connection command like the one below in VB6.

NOTE: This connection has been working in my computer, but on the client computer even after specifying the correct database and the server it still gives me problems (The error above).

objConn.Open "Driver=SQL Server;Server=" & SQLServer & ";" & "Database=" & SQLDB & ";"

if u can help please!! holla

LION OF JUDDAH!
__________________
LION OF JUDDAH!
 
Old August 21st, 2003, 10:37 AM
Ned Ned is offline
Authorized User
 
Join Date: Jun 2003
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Solution 1:
You can add UID=sa;pwd=; at the end of the connection string. Provided if you do not have password for sa and if you do then add UID=sa;pwd=yourpassword;

Solution 2:
Open the property window of the database in the Enterprise Manager and under Security tab change the authentication mode to SQL server and windows. Make sure that windows user has enough previliges to access the database.

Cheers,
-ned
 
Old February 12th, 2005, 10:22 PM
Authorized User
 
Join Date: Feb 2005
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I have tried both ways and none of them work. I will post the solution after I make it works.

James
Http://www.top-ink.com
www.top-ink.com
 
Old February 13th, 2005, 12:45 AM
Authorized User
 
Join Date: Feb 2005
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I just solved the problem by creating new user from database. You shall try to use those methods first, if it not works, create new user will be okay for you.

James
http://www.top-ink.com
www.top-ink.com
 
Old September 27th, 2006, 01:14 PM
Registered User
 
Join Date: Sep 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I just wanted to say thanks to Ned. I have been looking all over for a solution to a similar problem that i was having with an ASP page connecting to SQL on a separate server. I added "UID=sa;pwd=;" to my connect string and it worked.

Thanks again.







Similar Threads
Thread Thread Starter Forum Replies Last Post
Not associated with a trusted SQL Server connecti yoord BOOK: Beginning ASP.NET 1.0 6 April 15th, 2007 02:48 PM
Not associated with a trusted SQL Server connectio blajorthemajor SQL Server 2000 0 February 10th, 2006 07:30 PM
I NEED HELP WITH XALAN EXTENSION FOR SQL CONNECTIO JoaquinLR XSLT 0 December 22nd, 2005 04:50 PM
not associated with a trusted SQL Server Connectio jamesbie SQL Server 2000 1 February 24th, 2005 04:42 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.