Solved

Login Failed using SQL Server Authentication and Windows Authentication??

Posted on 2008-10-23
13
1,500 Views
Last Modified: 2012-05-05
I have just installed SQL Server 2005 Evaluation on a Windows Vista Home Premium PC.  I downloaded the application and Service Packs for SQL Server 2005 and Visual Studio 2005.  I would like to have SQL Server configured with the Mixed Mode for login (Windows and SQL Server Authentication).  

When ever I try to login using either modes, I get the following error ...

Login failed for user 'sa'. The user is not associated with a trusted SQL Server connection. (Microsoft SQL Server, Error: 18452)


Is there a way correct this error and possible set/reset/check the login modes.

Thanks,

ET

0
Comment
Question by:Eric Sherman
  • 7
  • 3
  • 2
  • +1
13 Comments
 
LVL 7

Expert Comment

by:Norush
ID: 22789937
This is probably caused by trying to connect to SQL Server when SQL Server is not configured for Mixed Mode authentication.
0
 
LVL 7

Expert Comment

by:Norush
ID: 22789940
Login as Local Administrator to your machine (SQL Server instance machine) and login to SQL Server instance using windows authentication.

(a) Then change the Authenticaiton mode to SQL Server and WIndows (mixed mode)

(b) Enable SA Login

(c) Restart the service
0
 
LVL 19

Author Comment

by:Eric Sherman
ID: 22789985
Norush ....

I've been trying to login as you described to no avail.

I am local administrator and when I get to the SQL Server Prompt I select windows authentication then the error pops up.  I can't logon using windows or sql server authentication.

ET
0
 
LVL 19

Author Comment

by:Eric Sherman
ID: 22790023
If I switch to login prompt to SQL Server Authentication then the following error pops up ...

Login failed for user 'sa'. The user is not associated with a trusted SQL Server connection. (Microsoft SQL Server, Error: 18452)


ET
0
 
LVL 3

Expert Comment

by:ScottyNewSuits
ID: 22790036
0
 
LVL 39

Accepted Solution

by:
BrandonGalderisi earned 500 total points
ID: 22790229
Login failed for user 'sa'. The user is not associated with a trusted SQL Server connection. (Microsoft SQL Server, Error: 18452)

means that SQL is setup for windows only auth which is the default

when you launch SSMS, right click > run as administrator > login with windows auth

it will work.
0
Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

 
LVL 19

Author Comment

by:Eric Sherman
ID: 22790359
Thanks Brandon ...  That seems to allow me to login using Windows Auth.  How can I change it to Mixed Mode (Windows & SQL Server Auth)??  When I go under Security I have a choice of one or the other, not both.

ET
0
 
LVL 19

Author Comment

by:Eric Sherman
ID: 22790396
Ignore the previous question ...  The second option allows for both (Windows & SQL Server auth).  I just did not read it completely.

ET
0
 
LVL 39

Expert Comment

by:BrandonGalderisi
ID: 22790429
Mixed mode = windows and SQL
0
 
LVL 19

Author Comment

by:Eric Sherman
ID: 22790447
>>>>when you launch SSMS, right click > run as administrator > login with windows auth<<<<

Is there a way to default the login as administrator or will I have to manuall right click it each time???

ET
0
 
LVL 39

Expert Comment

by:BrandonGalderisi
ID: 22790592
Welcome to Vista user access control :).  I think it's a worthwhile sacrafice.  PERHAPS you can create a shortcut that has an "always as admin" property, but that would be a vista thing and I don't have vista in front of me right now.  So look at shortcut vista options is I guess what I'm saying
0
 
LVL 19

Author Comment

by:Eric Sherman
ID: 22790646
Ok thanks and much appreciated.

I've been bouncing back and forth over the past few weeks between Windows XP and Vista.  My Vista machine had to go in for a repair and I was working on an XP machine to complete some development work.  Now that you mentioned it, I do remember when I first installed SQL Server on my Vista machine I was running it as Administrator from the Start Menu.  

You've answered my question.

ET
0
 
LVL 19

Author Closing Comment

by:Eric Sherman
ID: 31509385
Thanks!!!!
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Nowadays, some of developer are too much worried about data. Who is using data, who is updating it etc. etc. Because, data is more costlier in term of money and information. So security of data is focusing concern in days. Lets' understand the Au…
Having an SQL database can be a big investment for a small company. Hardware, setup and of course, the price of software all add up to a big bill that some companies may not be able to absorb.  Luckily, there is a free version SQL Express, but does …
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now