Hi friends, I have two table..
1) --------------------------------- users --------------------------------- id(pri) | user_name | email| ---------------------------------- 2) ----------------------------------------------- posts ----------------------------------------------- post_id | user_id(foreign_key)| title | body ------------------------------------------------- Relations is A user has many posts. I created a form for post. with title:----------------------------------- body:------------------------------------ ------------------------------------ ---------------------------------------- ----------------------------------------- submit_button. in controller I wrote logic for submit this form so that, all the title & body gets added into database. But, the foreign key is not being added. How am i suppose to do? -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---