From: Paul Date: 2005-10-28T00:02:03+09:00 Subject: Re: Ruby on Rails version of osCommerce in PHP? I can certainly agree with foreign key constraints; where possible these do help assure data integrity at the lowest possible layer. But these shouldn't replace similar contraints in the business logic. In particular, the UI is improved by better error reporting from the business logic which means catching problems there first. As for triggers and stored procedures, I'm not so neutral. Just as VB's promoted bad UI, I've seen DBAs go wild with stored procedures and you can have a mess on your hands there too. Any tool or system in the hands of the inexperienced can promote bad something-or-other. Good design is key. And rails and family do consistently access the database in the same way which may be how David rationalizes to himself what he says. If so, then that makes sense because rails also provides the ability to add messaging hooks (via ActiveWebService) to implement the integration mechanizms that he advocates. In another system, if this full stack weren't in place, then other mechanizms would be required because you'd be integrating at some point or other in the database (even if its only one system for web and other for messaging). Martin Fowler talks about this http://martinfowler.com/bliki/DatabaseStyles.html.