MS SQL Server 2008 R2Ok, so I've been under the impression that you couldn't turn db_chaining off on the system databases. Maybe I'm confusing myself, but this seems a little misleading:First I check the initial setting:select name, suser_sname(owner_sid) as owner,is_db_chaining_on chaining from sys.databases a where db_name() = 'master'name owner chainingmaster sa 1
Here I attempt to alter the server level settings for Cross DB ChainingUSE MASTER;GOsp_configure 'show advanced options', 1;GORECONFIGURE;GOsp_configure 'cross db ownership chaining', 0;GORECONFIGURE;GOConfiguration option 'show advanced options' changed from 1 to 1. Run the RECONFIGURE statement to install.Configuration option 'cross db ownership chaining' changed from 1 to 0. Run the RECONFIGURE statement to install.RECONFIGURE;Command(s) completed successfully
Note on how the change from 1 to 0 was successful, thus insinuating that disabling db_chaining on master was successful. However, when I rerun the query above, it shows:select name, suser_sname(owner_sid) as owner,is_db_chaining_on chaining from sys.databases a where db_name() = 'master'name owner chainingmaster sa 1
And when I run a query from the sys.configuration table I get:select db_name(), name, CAST(value as int) as value_configured, CAST(value_in_use as int) as value_in_use from sys.configurations where name like ('Cross db ownership%')(No column name) name value_configured value_in_usemaster cross db ownership chaining 0 0
So, what is going on here? One system view says that it is enabled when I successfully disabled it, and the other query show that it is in fact disabled.When I try to change the chaining on the database level, I get:EXEC sp_dboption master, 'db chaining', 'false'Msg 5600, Level 16, State 2, Line 1The Cross Database Chaining option cannot be set to the specified value on the specified database.Msg 5069, Level 16, State 1, Line 1ALTER DATABASE statement failed.sp_dboption command failed.
which is what I would expect. HELP!