user table
ID | name 1 | ada 2 | bob 3 | tom
Table
Table
ID | name 1 | group A 2 | group B 3 | group C
user_group table
user_id | group_id 1 | 1 2 | 1 1 | 2 2 | 2 3 | 2 1 | 3 3 | 3
This group of user identifiers: [1, 2, 3]
How to request a group to which all users from the above list belong? (in this case: group B)
source share