sysprotects (all databases)

For SQL Server 6.5 information, see sysprotects System Table in What's New for SQL Server 6.5.

Contains user permissions information ¾ entries for each GRANT and REVOKE statement that has been executed.

Column Datatype Description
id int ID of object to which this permission applies.
uid smallint ID of user or group to which this permission applies.
action tinyint One of the following permissions:
26        REFERENCES
193        SELECT
195        INSERT
196        DELETE
197        UPDATE
198        CREATE TABLE
203        CREATE DATABASE
207        CREATE VIEW
222        CREATE PROCEDURE
224        EXECUTE
228        DUMP DATABASE
233        CREATE DEFAULT
235        DUMP TRANSACTION
236        CREATE RULE
protecttype tinyint Either 205 (grant) or 206 (revoke).
columns varbinary(32) Bitmap of columns to which this SELECT or UPDATE permission applies. Bit 0 indicates all columns; bit 1 means permission applies to that column; NULL means no information.

Index

sysprotects clustered on id, uid, action

Referenced by Stored Procedures

sp_column_privileges sp_helprotect sp_table_privileges
sp_dropgroup sp_stored_procedures sp_tables
sp_dropuser