I am using SQL Server 2008 .My default schema is dbo. I have tables in schema dbo. But for some custom development I am planning to create a stored procedure in cdbo schema since it is a custom code. Can I access the tables of dbo schema from sp's of cdbo schema?
Asked
Active
Viewed 971 times
2
-
Also see http://stackoverflow.com/q/2212044/27535 – gbn Aug 24 '11 at 05:55
1 Answers
5
Yes, if the same principal (user) owns both schemas.
This the AUTHORIZATION bit in CREATE SCHEMA. If this is dbo for cdbo then no explicit permissions will be needed because of ownership chaining
CREATE SCHEMA cdbo AUTHORIZATION dbo;

gbn
- 422,506
- 82
- 585
- 676