Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- select b.Name, f.Name, r.* from building b
- left join floor f on f.BuildingId = b.BuildingId
- left join room r on r.FloorId = f.FloorId
- where r.AreaId = 5315
- select distinct b
- from Building b
- left join fetch b.floors f
- left join fetch f.rooms r
- where
- r.area.areaId = (?)
Add Comment
Please, Sign In to add comment