hi all, I have a table "memberships". It has a field user_id, which I want to use as a foreign key to the "users" table.
So, as far as I get it, in the membership model I have to write: has_many :users In the users model, I write: belongs_to :membership However(in case the above is correct), how do I ensure that if I delete a user, the related entities in membership will be also deleted?? Thank you :) -- 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 [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 -~----------~----~----~----~------~----~------~--~---

