What is the difference between "db_owner" and "the user that owns the database" in SQL Server 2000? What is the difference between "db_owner" and "the user that owns the database" in SQL Server 2000? sql sql

What is the difference between "db_owner" and "the user that owns the database" in SQL Server 2000?


No, db_owner and the owner of the database are not the same. dbo is a user and db_owner is a database role. Databases are owned by logins. Whatever login owns the database is aliased as dbo inside the database. You can change the database owner by using the sp_changedbowner system stored procedure.

All objects in a database are owned by a user. Users that are members of the db_owner role, among other permissions, are allowed to create objects owned by dbo. If a user is not a member of db_owner, but has some create permissions (e.g. Create Table), then any objects they create will be owned by the user that created them. You can change the ownership of an object using sp_changeobjectowner system stored procedure.