Users and roles

Database Explorer allows you to perform operations on users and roles using the shortcut menu. Right-click in Database Explorer to access commands for specific tasks, such as managing users or roles, or search for them in Security Manager.

Edit a user

To edit a user:

1. In Database Explorer, right-click the user and select Edit User.

2. In Security Manager that opens, update the user details.

3. To save the changes, select Save on the Security Manager toolbar. Alternatively, press Ctrl+S.

For more information, see Manipulate user accounts.

Edit a role

To edit a role:

1. In Database Explorer, right-click the role and select Edit Role.

2. In Security Manager that opens, update the role details.

3. To save the changes, select Save on the Security Manager toolbar. Alternatively, press Ctrl+S.

For more information, see Manipulate roles.

Edit an application role

To edit an application role:

1. In Database Explorer, right-click the application role and select Edit Application Role.

2. In Security Manager that opens, update the role details.

3. To save the changes, select Save on the Security Manager toolbar. Alternatively, press Ctrl+S.

For more information, see Manipulate roles.

Edit a schema

To edit a schema:

1. In Database Explorer, right-click the schema and select Edit Schema.

2. In Security Manager that opens, update the schema details.

3. To save the changes, select Save on the Security Manager toolbar. Alternatively, press Ctrl+S.

Note

You can create users, roles, application roles, or schemas only in Security Manager. To open Security Manager, navigate to the Database menu and select Security Manager.

Find in Security Manager

To find an object in Security Manager:

1. In Database Explorer, right-click the user, role, application role, or schema and their nodes select Find in Security Manager.

2. Security Manager opens, highlighting the object you were looking for.

Shortcut menu commands

The following table briefly explains the other shortcut commands available when you right-click an object in Database Explorer. The table includes each command description and its availability for different database object types.

Command Description
Duplicate Object Opens the Duplicate Object dialog to copy object structure and/or data.
Generate Script As Generates a script of the selected object using the CREATE, DROP, and DROP and CREATE statement. The script can be saved to a new SQL document or a file, or copied to the clipboard.
Show Details Opens Object Viewer to view object details.
Delete Drops the selected object from the database.
Alternatively, press Del.
Note: You cannot undo the drop object operation, as it permanently deletes all the object data and structure. It is recommended that you back up the database before deleting it. For instructions, see How to back up a SQL Server database.
Refresh Updates the object to reflect the latest changes.
Alternatively, press F5.
Properties Opens the Properties pane to view the object information.
Alternatively, press F4.