Skip to content
Tutorial Gateway
  • C
  • C#
  • Python
  • SQL
  • Java
  • JS
  • MySQL
  • BI Tools
    • Informatica
    • Talend
    • Tableau
    • Power BI
    • SSIS
    • SSRS
    • SSAS
    • MDX
    • R Tutorial
    • Alteryx
    • QlikView
  • More
    • C Programs
    • C++ Programs
    • Go Programs
    • Python Programs
    • Java Programs
    • Search
SQL Server Login Error 9

SQL Server Login Error

Login with SQL Server Authentication is throwing an error is a standard interview question. So, in this SQL Server article, we will show you the step-by-step approach to resolving Login Error. First, Let me show you the error. From the below screenshot, you can see the Login Error for user Suresh.

SQL Server Login Error Message 18456

Before we start doing anything to resolve SQL Server login errors, let me show you the list of available logins in our Management Studio. From the below screenshot, you can see that the Sql Server user exists. I suggest you refer to Create a Login article to understand the steps to create users.

SQL Server Login Errors to Access

If your account doesn’t have permission to log in, right-click on the Username and select properties from the context menu.

Go to properties in Object explorer security 3

Selecting the properties option will open the following window

User General Tab 4

Under the status tab, check the permissions to resolve the Login Errors.

  • Grant: Granting permission to users to connect with the database engine.
  • Enabled: Enable this user to login with his / her details.
Check Status Settings - Permission Grant or Deny 5

In most cases, the above-mentioned method will resolve the errors.

Sql Server Authentication Login Error Fix

In some cases, your database will accept only Windows authentication. In these cases, you have to change the authentication mode to dual. Right-click on the instance name and select the Properties option from the context menu

Right-Click on Server Instance and choose properties 6

It opens a properties window

Properties Window 7

Please navigate to the Security tab. From the below screenshot, you can see that the Server Authentication is selected in Windows Authentication Mode. It means it only accepts local Windows users.

Change the Server Authentication from Windows Mode 8

Please change the option to SQL Server and Windows Authentication Mode option.

SQL Server Login Error Authentication Mode 9

Click Ok. Remember, configuration changes will take effect only after the restart. So, restart the instance

Click Ok button to apply changes 10

Try with Username Suresh and server authentication.

Log in With server credentials 11

We successfully entered the management studio.

Management Studio 12
Back To Categories SQL
Python Program to Print Odd Numbers from 1 to N
Connect to SQL Server using sqlcmd utility

Related Topics

  • SQL Server Tutorial
  • SQL Database
    • Create Database
    • Attach Database
    • Detach Database
    • Get Database Names
    • Restore Database
    • Available Data Types
    • Create Table
    • Add a New Column
    • Alter Table
    • Derived Table
    • Get Column Names From Table
    • Get Table Names in a DB
    • Global & Local Temp Table
    • Rename Column Name
    • Table Name and Column Name
    • Table Variable
  • SQL Basic Commands
    • ALIAS
    • BULK INSERT or BCP
    • DML, DDL, DCL & TCL Cmds
    • DELETE Statement
    • INSERT Statement
    • INSERT INTO SELECT
    • SELECT Statement
    • SELECT DISTINCT
    • SELECT INTO Statement
    • TRUNCATE Statement
    • UPDATE Statement
    • UPDATE from SELECT
    • Query Builder
  • SQL Clauses
    • Introduction to Clauses
    • GROUP BY Clause
    • Having Clause
    • ORDER BY Clause
    • TOP Clause
    • WHERE Clause
  • SQL Joins
    • Types of JOINS
    • INNER JOIN
    • LEFT JOIN
    • RIGHT JOIN
    • FULL JOIN
    • SELF JOIN
    • CROSS JOIN
    • Cross Join Vs Inner Join
  • SQL Operators & NULLs
    • AND & OR Operators
    • Arithmetic Operators
    • BETWEEN Operator
    • Comparison Operators
    • COALESCE Function
    • EXCEPT
    • EXISTS Operator
    • INTERSECT
    • IN Operator
    • IS NOT NULL
    • IS NULL Function
    • ISNULL
    • LIKE Wildcard
    • NOT EXISTS Operator
    • NOT IN Operator
    • UNION
    • UNION ALL
  • SQL Control Flow
    • IIF Function
    • IF ELSE
    • ELSE IF
    • WHILE LOOP
    • BREAK
    • CONTINUE
    • GOTO Statement
    • CHOOSE
  • SQL Constraints
    • Constraints Introduction
    • Check Constraint
    • Clustered Index
    • Default Constraint
    • Non-Clustered Index
    • Primary Key
    • Foreign Key
    • Referential Integrity
    • Unique Constraint
    • Filtered Indexes
  • Advanced SQL Topics
    • CASE Statement
    • CDC Change Data Capture
    • CTE Example
    • MERGE Statement
    • PIVOT
    • Subquery
    • Table Partitioning
    • TRY CATCH
    • TRANSACTIONS
    • ACID Properties
    • VIEWS
    • User Defined Functions
    • UNPIVOT
  • SQL Stored Procedures
    • Stored Procedures Introduction
    • INSERT Stored Procedure
    • SELECT Stored Procedure
    • UPDATE Stored Procedure
    • Input Parameters in SP
    • Output Parameters SP
    • Insert SP result into Temp Table
    • Return Values in SP
    • Useful System SPs
  • SQL Triggers & Cursors
    • Introduction to Triggers
    • AFTER DELETE Triggers
    • AFTER INSERT Triggers
    • AFTER UPDATE Triggers
    • Instead Of DELETE Triggers
    • INSTEAD Of INSERT Triggers
    • INSTEAD of UPDATE Triggers
    • Static Cursor
    • Dynamic Cursor
    • FORWARD_ONLY Cursor
    • FAST_FORWARD Cursor
    • KEYSET Cursor
  • SQL Management Studio
    • How to Install SQL Server
    • Install Management Studio
    • Install AdventureWorks DB
    • Introduction to SSMS
    • Connect SQL with cmd utility
    • Backup Database
    • Create SQL Server Login
    • Create SQL Server Roles
    • Create Windows Login
    • Maintenance Plan
    • SQL Server Login Error
    • Uninstall Management Studio
  • SQL Aggregate Functions
    • Introduction to Aggregate
    • AVG Function
    • CHECKSUM_AGG Function
    • COUNT Function
    • COUNT_BIG function
    • GROUPING Function
    • GROUPING_ID Function
    • MIN Function
    • MAX Function
    • STDEV Function
    • STDEVP Function
    • SUM Function
    • VAR Function
    • VARP Function
  • Convert & Rank Functions
    • Introduce Conversions
    • CAST Function
    • TRY CAST
    • CONVERT
    • TRY CONVERT
    • PARSE Function
    • TRY_PARSE Function
    • Introduction to Ranking
    • RANK Function
    • DENSE_RANK
    • PERCENT_RANK
    • NTILE
  • SQL Date Functions
    • Introduction to Dates
    • GETDATE Function
    • GETUTCDATE Function
    • DAY Function
    • MONTH Function
    • YEAR Function
    • DATEADD
    • DATEDIFF
    • DATENAME
    • DATEPART
    • EOMONTH
    • DATEFROMPARTS
    • DATETIMEFROMPARTS
    • DATETIME2FROMPARTS
    • DATETIMEOFFESETFROMPARTS
    • SMALLDATETIMEFROMPARTS
    • TIMEFROMPARTS
    • TODATETIMEOFFSET
    • SWITCHOFFSET
    • SYSDATETIMEOFFSET
    • SYSUTCDATETIME
    • SYSDATETIME
    • DATEFIRST
    • @@DATEFIRST
    • @@LANGUAGE
    • SET DATEFORMAT
    • SET LANGUAGE
    • sp_helplanguage
    • CURRENT_TIMESTAMP
    • ISDATE
  • SQL Math Functions
    • Introduction to Math Functions
    • ABS Function
    • COS Function
    • ACOS Function
    • SIN Function
    • ASIN Function
    • ATAN Function
    • TAN Function
    • CEILING
    • FLOOR Function
    • EXP Function
    • LOG Function
    • LOG10 Function
    • POWER Function
    • RAND Function
    • RADIANS Function
    • SIGN Function
    • SQRT Function
  • SQL String Functions
    • Introduction to Strings
    • ASCII Function
    • CHAR Function
    • CONCAT Function
    • CONCAT_WS Function
    • CHARINDEX Function
    • DIFFERENCE Function
    • FORMAT Function
    • LEFT Function
    • LEN Function
    • LTRIM function
    • NCHAR Function
    • PATINDEX Function
    • QUOTENAME Function
    • REPLICATE Function
    • REPLACE Function
    • REVERSE Function
    • RTRIM Function
    • SPACE Function
    • SOUNDEX function
    • STR Function
    • STRING_AGG Function
    • STRING_ESCAPE Function
    • STRING_SPLIT Function
    • STUFF Function
    • SUBSTRING Function
    • TRANSLATE Function
    • TRIM Function
    • UPPER & LOWER Functions
    • UNICODE Function
  • Stats & Config Functions
    • Introduce Statistical Functions
    • Introduction to Configurations
    • @@CONNECTIONS
    • @@CPU_BUSY
    • @@IDLE
    • @@IO_BUSY
    • @@LANGID
    • @@LANGUAGE
    • @@MAX_CONNECTIONS
    • @@MAX_PRECISION
    • @@PACK_SENT
    • @@PACKET_ERRORS
    • @@PACK_RECEIVED
    • @@SERVICENAME
    • @@SERVERNAME
    • @@SPID
    • @@TIMETICKS
    • @@TOTAL_ERRORS
    • @@TOTAL_READ
    • @@TOTAL_WRITE
    • @@VERSION
  • Sys & Analytic Functions
    • Introduce System Functions
    • Introduce Analytic Functions
    • @@IDENTITY
    • ERROR LINE
    • ERROR MESSAGE
    • ERROR NUMBER
    • ERROR SEVERITY
    • ERROR STATE
    • HOST_ID
    • HOST_NAME
    • ISNULL
    • ISNUMERIC Function
    • FIRST_VALUE
    • LAST_VALUE
    • CUME_DIST
    • LAG Function
    • LEAD Function
    • PERCENTILE_DISC
    • PERCENTILE_CONT
    • SET Permission Functions
  • XML & FAQ’s
    • FOR XML AUTO
    • FOR XML PATH
    • FOR XML RAW
    • List Of Interview Questions
    • Calculate Running Total
    • Create ODBC Connection
    • Check if a Table exists
    • Configure SQL Database Mail
    • Concatenate Rows into String
    • Count Records in a Group
    • CTE Vs Temp Vs Derived tables
    • DATE Format
    • DATEPART Vs DATENAME
    • Delete Duplicate Rows
    • Extract Domain From Email
    • Export Data From SQL to CSV
    • Find the Table Dependencies
    • Find Nth Highest Salary
    • Find all Tables that Contain Specific Column Name
    • Get Last Record from each Group
    • IDENTITY INSERT
    • Identity Value Jumps after restarting SQL Server
    • Insert Images into SQL Server
    • Replace a String
    • Reverse String
    • Return Date Part Only from a Datetime datatype
    • Rows with Max Column Value
    • Swap Column Values
    • Standard Date Time Format Strings
    • Select First Row in each group
    • Select All If Parameter is Empty or NULL
    • Top N Records from each Group
    • UNION Vs UNION ALL
  Copyright © 2023. All Rights Reserved.
Home | About | Contact | Privacy Policy