Registrations are now open. Join us today!
There is still a lot of work to do on the wiki yet! More information about editing can be found here.
Already have an account?

Microsoft KB Archive/172751

From BetaArchive Wiki
Knowledge Base

BUG: Use of Sp_dboption by an Aliased DBO Fails with Error 15244

Article ID: 172751

Article Last Modified on 10/16/2003


  • Microsoft SQL Server 6.0 Standard Edition
  • Microsoft SQL Server 6.5 Standard Edition

This article was previously published under Q172751

BUG #: 16242 (6.5)
       15545 (6.0)


When an aliased database owner (DBO) attempts to change any of the database options using the sp_dboption system stored procedure, the following error message is raised from the stored procedure:

Msg 15244, Level 16, State 1
Only the System Administrator (SA) or the owner of the database may set
db options

Consider the following scenario:

Assume you have a login name of Raj aliased as the DBO in the pubs database. Log on as Raj and try to change the database option for the pubs database by executing the command below. You will encounter the error message described above.

   sp_dboption pubs, 'single', true

This behavior is incorrect; Raj should be able to change the database options.


SQL Server incorrectly checks the user validation in the sp_dboption system stored procedure for aliased DBOs.


To work around this problem, log on as a system administrator (SA) to be recognized as the only DBO who will be able to make database option changes using the sp_dboption system stored procedure.


Microsoft has confirmed this to be a problem in Microsoft SQL Server versions 6.0 and 6.5. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

Additional query words: alias

Keywords: kbbug kbprogramming kbusage kbsqlserv650bug KB172751