Update cookies preferences
Promotic

sp_addrolemember - statement of language DB_MSSQL

Description:
Adds an account as a database role member of the SQL Server in the current database. Then the account gets rights connected with the appropriate role in the SQL Server.
Syntax:

sp_addrolemember
  [ @rolename = ] 'role'
  [ @membername = ] 'security_acount'

@rolename Database role of the SQL Server into which the account will be added (db_ddladmin, db_datareader, db_datawriter).
@membername Account created in the certain database (sp_grantdbaccess) that will be added into the database role.
Note:
The database role holds for the certain database. The fixed role of the SQL Server holds globally in the SQL Server.
Example:
Adds the account 'pm_reader' into the database role of the SQL Server 'db_datareader' (this account can be used for reading data of the appropriate database).
USE pm_data
EXEC sp_addrolemember 'db_datareader', 'pm_reader'
PROMOTIC 9.0.31 SCADA system documentation MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r.o.