Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > SQL Server > SQL Server 2000 > SQL Server 2000
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
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 tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old May 24th, 2006, 07:34 AM
Authorized User
 
Join Date: Apr 2006
Location: , , .
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default 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.


Reply With Quote
  #2 (permalink)  
Old May 24th, 2006, 10:07 AM
joefawcett's Avatar
Wrox Author
Points: 9,763, Level: 42
Points: 9,763, Level: 42 Points: 9,763, Level: 42 Points: 9,763, Level: 42
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Exeter, , United Kingdom.
Posts: 3,074
Thanks: 1
Thanked 38 Times in 37 Posts
Default

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

--

Joe (Microsoft MVP - XML)
Reply With Quote
  #3 (permalink)  
Old May 30th, 2006, 12:28 PM
Authorized User
 
Join Date: Oct 2005
Location: , , .
Posts: 72
Thanks: 0
Thanked 0 Times in 0 Posts
Default

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
http://www.sql-server-helper.com
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Login failed for user. Protoman Classic ASP Databases 3 January 13th, 2008 01:23 PM
Funky - Login Failed for user 'Domain\UserId' erro jnks2005 ASP.NET 2.0 Basics 5 February 26th, 2007 01:38 PM
Getting 'Login failed for user ' Squeakrz44 VB.NET 2002/2003 Basics 0 November 18th, 2006 06:09 PM
login failed for user nt authority\anonymous login rj1406 Classic ASP Databases 1 October 24th, 2004 09:15 AM



All times are GMT -4. The time now is 04:42 PM.


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