• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Persistance Issue with EJB 3.0

 
Ramamoorthy Periasamy
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've defined the Inheritance strategy as InheritanceType.JOINED and got the entity class Vehicle and Truck extends Vehicle. I am using the derby database and have the tables created.

Vehicle has id(pk), name, wheels columns and Truck has id(fk), chase columns

When I try to persist these objects I am getting below exception. Please advice

Exception [TOPLINK-4002] (Oracle TopLink Essentials - 2006.8 (Build 060830)): oracle.toplink.essentials.exceptions.DatabaseException
Internal Exception: org.apache.derby.client.am.SqlException: 'DTYPE' is not a column in table or VTI 'APP.VEHICLE'.Error Code: -1
Call:INSERT INTO VEHICLE (ID, WHEELS, NAME, DTYPE) VALUES (?, ?, ?, ?)
bind => [1493225404, 4, GMC Truck 1, Truck]
Query:InsertObjectQuery(com.fruit.persistance.Truck@f30c34)
 
Ramamoorthy Periasamy
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I actually figured out the problem. Thanks anyway
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic