pepe wrote in post #955955: >> Use foreign key constraints in the database for this. The Foreigner gem >> will help manage these constraints. > > Yes, I think you're right and going with Referential Integrity should > be the way to go to make sure the rules are enforced at the DB level. > Although, I still would like to know how I can accomplish what I was > trying to do.
With foreign key constraints. There is really no reason to do it any other way. > > I didn't know about Foreigner and took a look. It seems that it is > meant to be used only with MySQL and PostgreSQL. I am using MSSQL and > have not found anything useful out there as gems/plugins go for this > DB. Any ideas? Yes, apparently you missed my announcement a couple months ago of my fork of Foreigner with MS SQL Server support: http://github.com/marnen/foreigner The gem is available as marnen-foreigner. I think sparkfly-foreigner also has MS SQL Server support. Best, -- Marnen Laibow-Koser http://www.marnen.org [email protected] -- 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.

