sys.sp_droprolemember
generalDescription
Analytics Platform System (PDW) Removes a security account from a SQL Server role in the current database. Syntax for SQL Server and Azure SQL Edge. Syntax for Azure Synapse Analytics and Analytics Platform System (PDW). This feature will be removed in a future version of SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.
Syntax
sp_droprolemember
[ @rolename = ]
N
'rolename'
, [ @membername = ]
N
'membername'
[ ; ]
sp_droprolemember
N
'rolename'
,
'membername'
[ ; ]
Arguments
database in Microsoft Fabric
Adds or removes members to or from a database role, or changes the name of a user-defined
database role.
Syntax for SQL Server (starting with 2012), Azure SQL Managed Instance, Azure SQL Database,
and Microsoft Fabric.
Syntax for SQL Server prior to 2012.
To add or drop members from roles in Azure Synapse Analytics and Analytics Platform
System (PDW) use
Examples
Example 1
sp_droprolemember
Example 2
sp_droprole
Example 3
ALTER
AUTHORIZATION
Example 4
sp_droprole
Example 5
CONTROL
Example 6
Sales
Example 7
EXECUTE sp_droprole
'Sales'
;
GO