Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Abstract Superclass DELETE not mapped error

 
Markus Schmider
Ranch Hand
Posts: 132
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 132
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
OK answer is
replace @MappedSuperclass with @Entity
MappedSuperclasses cannot be used in queries.

Question: Is there any advantage to use @MappedSuperclass instead of @Entity
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic