Wednesday, March 28, 2012

i created a login in SQL SERVER 2005 EXPRESS, but cant login...

create login dave with password='abc', default_database=tempdb

when i use this account to login my sql2005, i got

Msg 18452, Level 14, State 1, Server DAVID-398113F7C\SQLEXPRESS, Line 1
Login failed for user 'dave'. The user is not associated with a trusted SQL Serv
er connection.
why?You have probably installed the server such that it only allows Windows Authentication, so you cannot connect with a SQL login.

See the "How to: Change Server Authentication Mode" topic in Books Online for additional information on how to allow SQL authentication.

Thanks
Laurentiu|||follow the How to instruction, on right-click my sql server, i got a error msg. indicating that my server is not correctly registed !

in the reg. properity dialog box, i see my auth. mode is Windows Authentication, is there anything wrong with this ?|||Windows authentication means you can only connect with a Windows login. The login dave that you created is a SQL login, so it will not work if you only enabled Windows authentication. There is nothing wrong here, this is how it works.

However, the error message that you are getting when you right click on your server looks like a problem. You should post to SQL Server Tools General to find out what is wrong. If you cannot get an answer, please open a bug at http://lab.msdn.microsoft.com/productfeedback/Default.aspx.

In the meantime, you can try to change the authentication mode manually by modifying the following registry information to contain value 2 instead of 1:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL.1\MSSQLServer\LoginMode

1 means Windows authentication, this is the value you should find set. By changing this to 2, you'll set the mixed authentication mode. Be sure to restart the server for this change to take effect.

Thanks
Laurentiu|||thx! i changed the reg key, and it works fine now!

but, still, i cant get the server work, it popup a [SQL-DMO] errosTongue Tied|||Try posting on the SQL Server SMO/DMO forum with the text of the error and a description of the steps you took before you received it. There might be something wrong with your installation though. Have you tried installing on a different machine or reinstalling? Did you get any errors during the initial installation?

Thanks
Laurentiu

No comments:

Post a Comment