suppose I have 3 tables GrandCat, Cat, and Kitt. they have the one to many relation so I have the following classes. all association is lazy loading.
GrandCa
select distinct g from GrandCat g
inner join fetch g.cat c
inner join fetch c.kitten k
where g.age>10
and c.age>5
and k.color='yellow'
should do it fine. The returned grandcat will only have the wanted cats in its cats collection, and each cat will only have the wanted kitten in its kitten collection.
Be aware that although Hibernate returns entities, these entities do not reflect the reality of the associations. I would treat them as read-only objects, and not try to modify the associations in any way, because it could have disastrous side effects.