If I have some custom classes, like Foo, Bar and Baz and I map two of them (Foo and Bar) then if I try to load the unmapped Baz with a criteria, hibernate does not detect the error.
Code:
Criteria crit = getSession().createCriteria(Baz.class); // no error
...
List l = crit.list(); // no error here either
the returned list is empty.
There does not seem to be any SQL statements executed.
This is with hibernate 3.2.0.cr2 (inside JBoss 4.0.4GA).
Shouldn't hibernate throw some "UnmappedEntitiy" exception or similar ?
Regards,
David