I have 2 installations:
1. W2k with MS SQL 2000 sp2.
2. W2003 with MS SQL sp3.
There are two databases in all instalations: "maindb" and "userdb". The
table with data is in maindb.
In the 1'st installation I restict user access to all data in table in this
way:
- create user's login and user in databases maindb and userdb.
- create view in userdb with "where" clause as dbo (dbo is owner of this
view). This clause restict access to data. (create view userdb.dbo.tabl e as
select * from maindb.dbo.tabl e where ...)
- add user to group "Public" in maindb.
- add role "data reader" to user in userdb.
- effect: user can access data only by view, can not access any data in
maindb.
I do the same in secound installation:
- effect: user can not access data by view - message like this: "user
have not permission to select on maindb.dbo.tabl e"
Is this bug in sp3 or in sp2 ?
Is there another way to horizontal restrict access data in tables?
In Sybase ASE this method (restict by view) works ok. And there is new
property of ASE 12.5.1 - administrator can define context of login - the
"where" clause will be added automatically to any select.
Please help me. Thank You for any advice.
1. W2k with MS SQL 2000 sp2.
2. W2003 with MS SQL sp3.
There are two databases in all instalations: "maindb" and "userdb". The
table with data is in maindb.
In the 1'st installation I restict user access to all data in table in this
way:
- create user's login and user in databases maindb and userdb.
- create view in userdb with "where" clause as dbo (dbo is owner of this
view). This clause restict access to data. (create view userdb.dbo.tabl e as
select * from maindb.dbo.tabl e where ...)
- add user to group "Public" in maindb.
- add role "data reader" to user in userdb.
- effect: user can access data only by view, can not access any data in
maindb.
I do the same in secound installation:
- effect: user can not access data by view - message like this: "user
have not permission to select on maindb.dbo.tabl e"
Is this bug in sp3 or in sp2 ?
Is there another way to horizontal restrict access data in tables?
In Sybase ASE this method (restict by view) works ok. And there is new
property of ASE 12.5.1 - administrator can define context of login - the
"where" clause will be added automatically to any select.
Please help me. Thank You for any advice.
Comment