Group to Theme + bug correction

bug when we do a sql request on the group table