select * from (select a.id_group,
a.name_group, count(*) over (partition by a.id_group) size_group from groups a, users b where a.id_group=b.id_group) where size_group between 5 and 10
string= "[12344554788|John Doe]"
string= "первый юзер: [12344554788|John Doe] второй юзер: [09876654|Jane Doe] и остальные"