Is there a way to filter at the server level what data is returned to
clients by user? I know that I can create a user account and assign what
columns/tables the user account has access to, but what if I want them to
have full access to a table, but only certain records in that table. Any
ideas?To add more clarification:
Lets assume I have the following tables:
CUSTOMER:
ID CUSTOMER_NAME COMPANY
========================================
=============================
1 Customer 1 1
2 Customer 2 1
3 Customer 3 1
4 Customer 4 2
5 Customer 5 2
6 Customer 6 2
7 Customer 7 1
8 Customer 8 2
9 Customer 9 2
10 Customer 10 2
USERS:
ID USER_NAME
=======================================
1 User 1
2 User 2
3 User 3
4 User 4
COMPANY:
ID COMPANY_NAME
========================================
==
1 Company 1
2 Company 2
SECURITY:
USERID COMPANY_ID
========================================
1 1
1 2
2 1
3 2
4 1
4 2
Ok the application would know that if User 4 is pulling a list from the
CUSTOMER table to show the customers for both companies. Likewise if User 2
preformed the same action they should only see customers from Company 1.
My question is how to I get this same functionality from say Query Analyzer?
"John Harbison" <JohnH@.desertmicro.net> wrote in message
news:eZH9VUcwEHA.3528@.tk2msftngp13.phx.gbl...
> Is there a way to filter at the server level what data is returned to
> clients by user? I know that I can create a user account and assign what
> columns/tables the user account has access to, but what if I want them to
> have full access to a table, but only certain records in that table. Any
> ideas?
>|||Check
http://vyaskn.tripod.com/ row_level...s
es.htm.
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com
"John Harbison" <JohnH@.desertmicro.net> wrote in message
news:%231TwA$cwEHA.2908@.tk2msftngp13.phx.gbl...
> To add more clarification:
> Lets assume I have the following tables:
> CUSTOMER:
> ID CUSTOMER_NAME COMPANY
> ========================================
=============================
> 1 Customer 1 1
> 2 Customer 2 1
> 3 Customer 3 1
> 4 Customer 4 2
> 5 Customer 5 2
> 6 Customer 6 2
> 7 Customer 7 1
> 8 Customer 8 2
> 9 Customer 9 2
> 10 Customer 10 2
>
> USERS:
> ID USER_NAME
> =======================================
> 1 User 1
> 2 User 2
> 3 User 3
> 4 User 4
>
> COMPANY:
> ID COMPANY_NAME
> ========================================
==
> 1 Company 1
> 2 Company 2
>
> SECURITY:
> USERID COMPANY_ID
> ========================================
> 1 1
> 1 2
> 2 1
> 3 2
> 4 1
> 4 2
>
> Ok the application would know that if User 4 is pulling a list from the
> CUSTOMER table to show the customers for both companies. Likewise if User
2
> preformed the same action they should only see customers from Company 1.
> My question is how to I get this same functionality from say Query
Analyzer?
>
> "John Harbison" <JohnH@.desertmicro.net> wrote in message
> news:eZH9VUcwEHA.3528@.tk2msftngp13.phx.gbl...
what[vbcol=seagreen]
to[vbcol=seagreen]
Any[vbcol=seagreen]
>
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment