Sunday, February 12, 2012

Connection Problems

Hi,

I am new to SQL Server 2005 but have a pretty good understanding of 2000, but I am struggling with connections! I have created a .Net Windows application (installed on an XP box) that should talk to a SQL Server 2005 database which is installed on a 2003 server. The desktop app is installed is in one domain (DOM1), and the SQL server 2005 is in another domain (DOM2). I have created a active directory user in DOM2 which will be a service account which manages the connections between the app and the db. I am using the following connection string:-

Server=ZZLUKGKK1M1J\INST2005;Database=PublicationWizard;User ID=DOM2\zzPubWizardDBUser;Password=password;Network Library=DBMSSOCN;Trusted_Connection=False;

When I try and connect an error is thrown, and I get the following in the SQL log

Error: 18456, Severity: 14, State: 5.

Login failed for user 'DOM2\zzPubWizardDBUser'. [CLIENT: 10.80.150.121]

I know that the user name and password are correct and that it exists with the DOM2 domain. I have also included "Network Library=DBMSSOCN" as I was getting problems with it trying to connect via Named Pipes. As I am really used to SQL Server 2000 I might be missing something obvious but I cannot for the life of me figure this out.

Any suggestions will be most welcome as this is driving me nuts

by setting trusted_connection=false you are implying you wish to use SQL Authentication not Windows. Thus your user must be created on the destination sql server and sql authentication must be enabled on the server itself.

No comments:

Post a Comment