How to Enable ‘sa’ Login in SQL Server

317views

If you select Windows authentication mode during SQL Server installation then ‘sa’ login is not enabled and you have to enable it manually if you want to use it. Due to security reasons it is recommended not to enable ‘sa’ login unless you need this login seriously. Also set strong password with combination of alpha numeric and special characters. You can use ALTER LOGIN statement to enable ‘sa’ login with T-SQL or you can reset by using SQL Server Management Studio.

Enable ‘sa’ Login with SSMS

You can enable ‘sa’ login by following below path in SSMS.

Go to Object Explorer –> expand Security option–> expand Logins –> right click on ‘sa’ and select Properties. You will get below login properties window.

Now, here in password field you can set the new password for ‘sa’ login. Now go to Status page and select Enabled option for login ‘sa’ and click OK as shown below.

sa Login Status

Enable ‘sa’ Login with T-SQL

You can also set the ‘sa’ login password and enable the same with following T-SQL command.

ALTER LOGIN sa ENABLE
GO
ALTER LOGIN sa WITH PASSWORD = 'B@6P@$$w0r6'
GO

CLICK HERE to watch live practical.

Reference: Manzoor Siddiqui [www.SQLServerLog.com]

You may also like

You may also like...

Leave a Reply