How to filter sp_helprotect information

DECLARE @sp_helprotect TABLE 
( 
    [Owner] VARCHAR(255), 
    [Object] VARCHAR(255) NULL, 
    [Grantee] VARCHAR(255) NULL, 
    [Grantor] VARCHAR(255) NULL,     
    [ProtectType] VARCHAR(255) NULL, 
    [Action] VARCHAR(255) NULL, 
    [Column] VARCHAR(255) NULL
) 
 
INSERT @sp_helprotect EXEC sp_helprotect 
SELECT * FROM @sp_helprotect
WHERE [Object] = 'table-name'
 ORDER BY [Object], [Grantee], [Action]

Comments

Popular posts from this blog

Tibco Rendezvous (tibrv) C# .Net example

Parse XML to dynamic object in C#