Hi,
i have following Problem: I have 2 Classes, A and B while B is a Subclass of A, but their mapping is completly independent from each other (no Inheritance-Strategy definied). In my opinion hibernate should handle them as 2 different and indipendent entities.
But when I try to query the superclass A: - session.createQuery("FROM A").list(); hibernate queries both tables and I dont know really why. If set an entity-name (Foo) in the mapping file of A and change the query like this - session.createQuery("FROM Foo).list(); everything works just fine. I really dont get this...
Thanks for your help!
Sebastian
|