MS SQL Server 2012 - DBA Articles

CREATE LOGIN to connect SQL Server Instance

This article describes how to create a login in SQL Server 2012 by using SQL Server Management Studio or Transact-SQL. A login is the identity of the person or process that is connecting to an instance of SQL Server.
To create a SQL Server login
To open SQL Server Management Studio, in the Search charm, under Apps, type SQL and then click SQL Server Management Studio option.

Select SQL Server Name and then click Connect.

In Object Explorer, expand the folder of the server instance in which you want to create the new login.

Right-click the Security folder, point to New, and select Login....

In the Login - New dialog box, on the General page, enter the name of a user in the Login name box.

Alternately, click Search... to open the Select User or Group dialog box. If you click Search...:
A) Under Select this object type, click Object Types... to open the Object Types dialog box and select any or all of the following: Built-in security principals, Groups, and Users. Built-in security principals and Users are selected by default. When finished, click OK.

B) Under From this location, click Locations... to open the Locations dialog box and select one of the available server locations. When finished, click OK.

C) Under Enter the object name to select (examples), enter the user or group name that you want to find.

D) Click Advanced... for more advanced search options.
E) Click OK.
To create a login based on a Windows principal, select Windows authentication. This is the default selection.

From the Default database list, select a default database for the login. Master is the default for this option.

From the Default language list, select a default language for the login.

Click Server Roles pane.

The Server Roles page lists all possible roles that can be assigned to the new login.

PUBLIC is default role and additionally, selected SYSADMIN role to maintain this SQL Server Instance by this user. User Mapping and Securables panes will discuss in the other articles.
Click Status pane.

The Status page lists some of the authentication and authorization options that can be configured on the selected SQL Server login.

The following options are available on this page:
Permission to connect to database engine
When you work with this setting, you should think of the selected login as a principal that can be granted or denied permission on a securable.
Select Grant to grant CONNECT SQL permission to the login. Select Deny to deny CONNECT SQL to the login.
When you work with this setting, you should think of the selected login as a record in a table. Changes to the values listed here will be applied to the record.
A login that has been disabled continues to exist as a record. But if it tries to connect to SQL Server, the login will not be authenticated.
Select this option to enable or disable this login. This option uses the ALTER LOGIN statement with the either ENABLE or DISABLE option.

Email Your Comment To AUTHOR