1 | public void testNestedCollectionFetch() {↵ | | 1 | public void testDeleteSyntaxWithCompositeId() {↵
|
2 | Session s = openSession();↵ | | 2 | Session s = openSession();↵
|
3 | Transaction t = s.beginTransaction();↵ | | 3 | Transaction t = s.beginTransaction();↵
|
|
4 | s.createQuery("from Animal a left join fetch a.offspring o left join fetch o.offspring where a.mother.id = 1 order by a.description").list();↵ | | 4 | s.createQuery( "delete EntityWithCrazyCompositeKey where id.id = 1 and id.otherId = 2" ).executeUpdate();↵
|
5 | s.createQuery("from Zoo z left join fetch z.animals a left join fetch a.offspring where z.name ='MZ' order by a.description").list();↵ | | 5 | s.createQuery( "delete from EntityWithCrazyCompositeKey where id.id = 1 and id.otherId = 2" ).executeUpdate();↵
|
6 | s.createQuery("from Human h left join fetch h.pets a left join fetch a.offspring where h.name.first ='Gavin' order by a.description").list();↵ | | 6 | s.createQuery( "delete from EntityWithCrazyCompositeKey e where e.id.id = 1 and e.id.otherId = 2" ).executeUpdate();↵
|
|
7 | t.commit();↵ | | 7 | t.commit();↵
|
8 | s.close();↵ | | 8 | s.close();↵
|
9 | | | 9 |
|