Problem: During a logon process to SQL server the following error may appear: “Login failed for user ‘username’. The user is not associated with a trusted SQL Server connection. (Microsoft SQL Server, Error: 18452)”.

Cause (for me anyway): The SQL server has been configured to operate inĀ “Windows Authentication Mode (Windows Authentication)” and doesn’t allow the use of SQL accounts.

Solution: Change the Authentication Mode of the SQL server from “Windows Authentication Mode (Windows Authentication)
to “Mixed Mode (Windows Authentication and SQL Server Authentication)“.

How:

  1. Open SQL Management Studio and log in
  2. Right-click the Server, Select Properties, Select Security
  3. Switch to SQL Server and Windows Authentication Mode.
  4. Restart server: Right click server, select Restart