REASSIGN OWNED
SQL - Language Statements
REASSIGN OWNED
change ownership of database objects owned by a database role
REASSIGN OWNED
REASSIGN OWNED old_role [, ...] TO new_role
Description
The REASSIGN OWNED instructs the system to change
the ownership of the database objects owned by one of the old_roles,
to new_role.
Notes
The REASSIGN OWNED command is mostly used in preparation to
drop the roles. See the DROP OWNED command for an
alternative that drops the objects.
The REASSIGN OWNED command does not affect the privileges
granted to the old_roles in objects not owned by them. Use
DROP OWNED to remove them.
Compatibility
The REASSIGN OWNED statement is a
PostgreSQL extension.
See Also