jQuery in Action, 2nd edition*
The moose likes Object Relational Mapping and the fly likes Abstract Superclass DELETE not mapped error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Abstract Superclass DELETE not mapped error" Watch "Abstract Superclass DELETE not mapped error" New topic
Author

Abstract Superclass DELETE not mapped error

Markus Schmider
Ranch Hand

Joined: Feb 25, 2007
Posts: 109
Hello,

using hibernate-jpa-2.1-api 1.0.0.Final, hibernate-entitymanager 4.0.1.Final
I want to use an abstract superclass


When I run the named queries I get


How can I find all instances or delete all instances in this kind of class hierachy?

Thanks

Hans
Markus Schmider
Ranch Hand

Joined: Feb 25, 2007
Posts: 109
OK answer is
replace @MappedSuperclass with @Entity
MappedSuperclasses cannot be used in queries.

Question: Is there any advantage to use @MappedSuperclass instead of @Entity
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Abstract Superclass DELETE not mapped error