metaclass (metaclass) wrote,
metaclass
metaclass

Рельсы и констрейнты в БД

http://guides.rubyonrails.org/migrations.html#active-record-and-referential-integrity
"The Active Record way claims that intelligence belongs in your models, not in the database. As such, features such as triggers or foreign key constraints, which push some of that intelligence back into the database, are not heavily used."

В ActiveRecord червь не рекомендует делать констрейнты в БД. Это огорчение, т.к. например, я сломал к хуям (т.е. до невозможности вообще хоть что-либо сделать из UI) хипстерское веб-приложение одним SQL-запросом :)
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 89 comments