Hibernate version: 1.2.0
I've brought up issues with the .class keyword in HQL before and here I go again...*sigh*
At the moment the behavior of the .class keyword does not seem to be polymorphic (at least when using joined-subclass) and will only return the explicit type specified rather than that type and it's subtypes.
For example, if I have an <any> collection mapping which contains entities derived from an abstract Person class (say, Lecturer and Student) and I try to select all entities of type Person using ".class = Person" I will get no results back.
Is this behavior by design?
Cheers,
Symon.
|