metaclass: (Default)
[personal profile] 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-запросом :)

Date: 2013-07-30 06:53 pm (UTC)
From: [identity profile] sergiej.livejournal.com
хорошо, зачем тебе констрейнт на поле с ФК в таблице? Может это я не вьехал.

Profile

metaclass: (Default)
metaclass

April 2017

S M T W T F S
      1
2345678
9101112 131415
16171819202122
23242526272829
30      

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jun. 8th, 2025 05:48 pm
Powered by Dreamwidth Studios