REASSIGN OWNED

Function

Changes the owner of a database.

REASSIGN OWNED requires that the system changes the owner of all the database objects owned by old_role to new_role.

Precautions

Syntax

1
REASSIGN OWNED BY old_role [, ...] TO new_role;

Parameter Description

Examples

Reassign all database objects owned by the joe and jack roles to admin:

1
REASSIGN OWNED BY joe, jack TO admin;