Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
Christech82
Starting Member
20 Posts |
Posted - 2013-05-02 : 15:57:57
|
Hi there I would like to now how do I let the clerk Privileges by using ROLE on certain table are:Client, Contracts and productsI need to know what is the first step that I can do and then granting the privileges according to these table ? Thank you |
|
Bustaz Kool
Master Smack Fu Yak Hacker
1834 Posts |
Posted - 2013-05-02 : 18:08:39
|
1) Create the Role[CODE]CREATE ROLE MyRole;[/CODE]2) Add the Users into the Role[CODE]EXEC sp_AddRoleMember 'MyRole', 'User1';EXEC sp_AddRoleMember 'MyRole', 'User2';[/CODE]3) GRANT the desired privileges to the Role[CODE]GRANT SELECT ON OBJECT::Client to MyRole;GRANT SELECT ON OBJECT::Contracts to MyRole;GRANT SELECT ON OBJECT::Products to MyRole;[/CODE]=================================================There are two kinds of light -- the glow that illuminates, and the glare that obscures. -James Thurber |
|
|
|
|
|