Changing Database Ownership

You can change the owner of a database. This drops the aliases of users who could act as the old DBO. You might want to change the database owner, for example, when you create a new database yourself but want to assign ownership of the database to another user.

The new owner must not already be known in the database as a user or have an alias. It may be necessary to drop a user from a database or from an alias before changing a database's ownership.

You must be in the database for which the ownership is being changed.

    To change the database owner

For example, to make maryd the owner of the current database and drop aliases of users who could act as the old DBO, type:

sp_changedbowner maryd

You cannot change the ownership of the master database.

For more information on using sp_changedbowner, see the Microsoft SQL Server Transact-SQL Reference.