On Fri, Mar 5, 2010 at 7:22 AM, M I R <[email protected]> wrote: > Hi, > I want to insert data into multiple database tables from a single > form, look at the detail. > > tables: patients, patient_history, patient_address, > > first i will insert data into patient table and then the patient > primary key will be used as foreign key in patient_history and > patient_address from a single form. There is another issue that > patient history will be multiple (ajax will be used to add multiple > entries) > > http://www.thatsquality.com/examples/author-form > > This example will give you the idea of adding multiple forms. It is > for symfony which use the concept of embedded form which provide > symfony. How will i add this functionlity in rails, please help. >
Hi, Ryan Bates did two episodes of Railscasts recently that will help you: http://railscasts.com/episodes/196-nested-model-form-part-1 http://railscasts.com/episodes/197-nested-model-form-part-2 -- Gael Muller -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

