select
groups.id_group,
groups.name_group,
count(distinct users.id_user) size_group
from groups
join users on users.id_group = groups.id_group
group by groups.id_group, groups.name_group
having count(distinct users.id_user) between 1 and 5
;