Hi
How can I get information of permission of a user to an object in a database
.
Even if the permission was granted to the user any way:
by a database role
by an aplication role
by direct grant
by the user member of an NT group which group is in 'users' on the database
(trusted conn.)
etc.
I have to know after the connect to the database if the user have permission
or not to read - write the database tables.
Thank for any idea.
Imre AmentCheck out sp_helprotect in the BOL.
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinnaclepublishing.com/sql
"permission to an object" <permission to an
object@.discussions.microsoft.com> wrote in message
news:BE12E14B-915E-4D6B-B5A1-08ACB267E757@.microsoft.com...
Hi
How can I get information of permission of a user to an object in a
database.
Even if the permission was granted to the user any way:
by a database role
by an aplication role
by direct grant
by the user member of an NT group which group is in 'users' on the database
(trusted conn.)
etc.
I have to know after the connect to the database if the user have permission
or not to read - write the database tables.
Thank for any idea.
Imre Ament|||Hi,
To see the object level permissions granted using "GRANT"statement see
sp_helprotect <object_name>,'user_name'
To see the assigned roles to the user in all database, execute below
sp_helplogins <Login_name>
To see the roles in a partcular database
use <dbname>
go
sp_helpuser <user_name>
Thanks
Hari
MCDBA
"permission to an object" <permission to an
object@.discussions.microsoft.com> wrote in message
news:BE12E14B-915E-4D6B-B5A1-08ACB267E757@.microsoft.com...
> Hi
> How can I get information of permission of a user to an object in a
database.
> Even if the permission was granted to the user any way:
> by a database role
> by an aplication role
> by direct grant
> by the user member of an NT group which group is in 'users' on the
database (trusted conn.)
> etc.
> I have to know after the connect to the database if the user have
permission or not to read - write the database tables.
> Thank for any idea.
> Imre Ament
>
No comments:
Post a Comment