How to exclusively generate a script of object-level permission?

  • I do not need any other script but the object-level permission on a database. Does anyone know how to do it?

    Any input will be greatly appreciated in advance.

  • select U.name as username,

    O.name as object,

    permission_name as permission

    from sys.database_permissions

    join sys.sysusers U on grantee_principal_id = uid

    join sys.sysobjects O on major_id = id

    order by U.name

    Greg

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply