p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   SQL Server 2000 (http://p2p.wrox.com/forumdisplay.php?f=20)
-   -   login failed for user domain\user (http://p2p.wrox.com/showthread.php?t=42953)

babakwx May 24th, 2006 07:34 AM

login failed for user domain\user
I've developed an ASP .Net 2 application. Locally, everything was fine. However, when I deployed it on a remote server. I got this error:

Login failed for user 'domain\userx'.

My connection string is:
connectionString="Data Source=ServerName;Initial Catalog=Aspect;User Id =domain\userx;Password = abc"

I'm quite sure that connection string is fine. I need to mention that whenever I try to connect to the remote server from my client by the Sql authentication, I get the message that login failed for this user. But when I try to connect by windows authentication, it works and there is no error.
I asked the administrator, and he told me that Sql Server authentication is in mixed mode.
So, I really can't figure out what is the problem.

joefawcett May 24th, 2006 10:07 AM

You need a SQL login, not a windows login for this to work.


Joe (Microsoft MVP - XML)

sshelper May 30th, 2006 12:28 PM

To connect to SQL Server using Windows Authentication, your connection string will look like this:

"Data Source=ServerName;Initial Catalog=Aspect;Integrated Security=SSPI;"

SQL Server Helper

All times are GMT -4. The time now is 10:30 PM.

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