REASSIGN OWNED

Function

REASSIGN OWNED changes the owner of the database object.

REASSIGN OWNED requires the system to change the owners of all database objects owned by old_role in the current database to new_role.

Precautions

  • REASSIGN OWNED is often executed before role deletion.
  • To run the REASSIGN OWNED statement, you must have the permissions of the original and target roles.

Syntax

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

Parameter Description

  • old_role

    Specifies the role name of the old owner.

  • new_role

    Specifies the role name of the new owner.

Examples

None

Feedback
编组 3备份
    openGauss 2024-10-08 01:19:39
    cancel