Simply update the use statement with your database name and run the query, it will show you all your denies on database objects and to what role and user they are denied
2016-05-23
1,394 reads
Captain DBA,
2015-01-14 (first published: 2014-12-17)
Simply update the use statement with your database name and run the query, it will show you all your denies on database objects and to what role and user they are denied
USE <yourdatabasenamehere> SELECT l.name as grantee_name, p.state_desc, p.permission_name, o.name FROM sys.database_permissions AS p JOIN sys.database_principals AS l ON p.grantee_principal_id = l.principal_id JOIN sys.sysobjects O ON p.major_id = O.id WHERE p.state_desc ='DENY'
2016-05-23
1,394 reads
2016-06-20
1,272 reads
2014-03-07
1,879 reads
2009-04-09 (first published: 2009-03-16)
1,343 reads