I am writing a JPQL query and i have the following scenario. I have a Question entity which contains a list of Tags. I would like to select all Questions that contains a gi
select distinct q from Question q join q.tags as t
where t.name in (:tags)
group by q.id, q.author, q.title, q.content,q.postedAt
having count(t.id) = :size