Some helpful queries related to groups are described in this section. These queries are based on the information presented in this chapter.
The following query retrieves information about a group named interviewers:
SELECT group_name, group_address, owner_name, group_admin FROM dm_group WHERE group_name = 'interviewers'
The following query retrieves the names of the groups that a user named dmadmindev
is a member of, directly or indirectly (through nested group memberships):
SELECT group_name FROM dm_group WHERE ANY i_all_users_names = 'dmadmindev'
The following query retrieves the names of the users and groups that are direct members of a group named admingroup:
SELECT users_names, groups_names FROM dm_group WHERE group_name = 'admingroup'
The following query retrieves the names of all the roles present in the repository:
SELECT group_name FROM dm_group WHERE group_class = 'role'