File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
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
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Child object is not saving." Watch "Child object is not saving." New topic

Child object is not saving.

pankaj semwal
Ranch Hand

Joined: Oct 07, 2008
Posts: 303

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?
I agree. Here's the link:
subject: Child object is not saving.
It's not a secret anymore!