Hi,
I would like to know how to get all the login names in a server that have a
certain privilege.
Such as I want to get all the logins that have an update privileges to a
table.
Thanks in advance
Frank
Hi,
Have a Look into sysprotects table. You could right a stored procedure to
query the sysprotects table in all the database where
a user have access.
Thanks
Hari
SQL Server MVP
"Frank" <wangping@.lucent.com> wrote in message
news:ehbHb51YFHA.3620@.TK2MSFTNGP09.phx.gbl...
> Hi,
> I would like to know how to get all the login names in a server that have
> a
> certain privilege.
> Such as I want to get all the logins that have an update privileges to a
> table.
> Thanks in advance
> Frank
>
|||While the information is in the sysprotects table, the difficult part is
that you must go through all of the groups that the user is a member of as
well... IF the user has 3 grants on a particular table, but is a member of
a group which is denied to the table, the permission is deny...
Also remember that is the object owners are the same, and the user is denied
to the table, but granted to a view on the table, he can access the table
via the view...
So doing this gets complicated very quickly... I would search for scripts on
the web as well.
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Frank" <wangping@.lucent.com> wrote in message
news:ehbHb51YFHA.3620@.TK2MSFTNGP09.phx.gbl...
> Hi,
> I would like to know how to get all the login names in a server that have
> a
> certain privilege.
> Such as I want to get all the logins that have an update privileges to a
> table.
> Thanks in advance
> Frank
>
No comments:
Post a Comment