Groups Members Table Schema (groups_members)


Description

Link a user to a group.

groups_members table columns

Column Type Size Nulls Auto Default Children Parents Comments
id BIGINT 19 null
groupid BIGINT 19 0
groups.id groumemb_gro2_fk R
userid BIGINT 19 0
user.id groumemb_use2_fk R
timeadded BIGINT 19 0
component VARCHAR 100

Defines the Moodle component which added this group membership (e.g. 'auth_myplugin'), or blank if it was added manually. (Entries which are created by a Moodle component cannot be removed in the normal user interface.)

itemid BIGINT 19 0

If the 'component' field is set, this can be used to define the instance of the component that created the entry. Otherwise should be left as default (0).

Table contained -1 rows

groups_members table indexes

Constraint Name Type Sort Column(s)
PRIMARY Primary key Asc id
groumemb_gro_ix Performance Asc groupid
groumemb_use_ix Performance Asc userid
groumemb_usegro_uix Must be unique Asc/Asc userid + groupid

groups_members table relationships