0

hi there,
i have a question in giving access to separate table to users.

i have a database call Admin and in that there are some tables that the one user should not aloowed in viewing,
how can i restric that user in avoing looking at that table
i am using MS SQL 2008.

appriciate a lot

if someoen can guide me
thanxxxxxx

2
Contributors
3
Replies
4
Views
6 Years
Discussion Span
Last Post by buddylee17
0

There are many ways to do this, but here's one way to do it from the Management Studio:
Under the server, expand security and expand Logins.
Create a new login.
Under Server Roles, keep the login as Public.
Under User mapping, check the database that you want the user to have access to.
Under database role membership, give the user the appropriate role (db_datareader, db_datawriter...).
Click Ok.

Under the database, expand users and double click the user.
Under securables, click Search button, and select object types, tables. Check the table and click ok.
At the bottom, explicitly deny permissions to the table.

There are many other ways to accomplish this, but this way will work.

Edited by buddylee17: n/a

0

There are many ways to do this, but here's one way to do it from the Management Studio:
Under the server, expand security and expand Logins.
Create a new login.
Under Server Roles, keep the login as Public.
Under User mapping, check the database that you want the user to have access to.
Under database role membership, give the user the appropriate role (db_datareader, db_datawriter...).
Click Ok.

Under the database, expand users and double click the user.
Under securables, click Search button, and select object types, tables. Check the table and click ok.
At the bottom, explicitly deny permissions to the table.

There are many other ways to accomplish this, but this way will work.

hey thanx
i have another question as well

how can i hame a grop call Solar and then add users to that group and then give access to that group so that the users in those group has different permissions

please can u help me thins

thanxxx
appriciate a lot
thanxxxxx

0

There are 2 parts to this. The first part (creating the group and adding users) is done at the server level.

Click Start->Administrative Tools->Computer Management.
Click Local Users and groups. Open groups. Right click and select Add Group.
Name your group and apply server level permissions.
After you create the group, add the users.

Log into Sql Server Management Studio.
Create a login that uses Windows Authentication. Use the new group as the username. Assign server permissions. Assign database permissions.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.