This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes JSP and the fly likes Submit parent and child records using JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Submit parent and child records using JSP" Watch "Submit parent and child records using JSP" New topic
Author

Submit parent and child records using JSP

Shridhar Raghavan
Ranch Hand

Joined: May 27, 2010
Posts: 71
Hi,

Been a long time. :-). I need to post from the browser the 1:m db relationship in one go. That i to say, insert the parent and child records in one go. I wanted to know how do i go about this. Prefer to accomplish this only through JSP and not involve Javascript. What i have been thinking is the jsp page first loads with a simple text field asking the number of child records. This is posted back to same jsp page which then renders itself with the parent form and equal number of forms for the child table. Is this fine and if so, how can i access the multiple form data through servlets.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Submit parent and child records using JSP