Viewing Users and Groups (Roles)

Viewing Users and Groups (Roles)

It is frequently convenient to group users (roles) together to ease management of object privileges: that way, privileges can be granted to, or revoked from, a group as a whole. In Greenplum Database this is done by creating a role that represents the group, and then granting membership in the group role to individual user roles.

The gp_roles_assigned view can be used to see all of the roles in the system, and their assigned members (if the role is also a group role).

gp_roles_assigned

This view shows all of the roles in the system, and their assigned members (if the role is also a group role). This view is accessible to all users.

Table 1. gp_roles_assigned view
Column Description
raroleid The role object ID. If this role has members (users), it is considered a group role.
rarolename The role (user or group) name.
ramemberid The role object ID of the role that is a member of this role.
ramembername Name of the role that is a member of this role.