This week's book giveaway is in the Android forum.
We're giving away four copies of Head First Android and have Dawn & David Griffiths on-line!
See this thread for details.
The moose likes Object Relational Mapping and the fly likes Child object is not saving. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Head First Android this week in the Android forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Child object is not saving." Watch "Child object is not saving." New topic
Author

Child object is not saving.

pankaj semwal
Ranch Hand

Joined: Oct 07, 2008
Posts: 301

I have a screen where parent table has two child and having one to one mapping between parent and child's.

I want if parent is saved then child should automatically saved.But this not happening.
Where Student is parent and school and scast are its child.

Please help me....


Below are my HBM files.



Java code
Sridhar Santhanakrishnan
Ranch Hand

Joined: Mar 20, 2007
Posts: 317
How about saving the school object instead of student?
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Child object is not saving.
 
jQuery in Action, 3rd edition