Re: multi column foreign key for implicitly unique columns
От | Jan Wieck |
---|---|
Тема | Re: multi column foreign key for implicitly unique columns |
Дата | |
Msg-id | 4123D91D.8060601@Yahoo.com обсуждение исходный текст |
Ответ на | Re: multi column foreign key for implicitly unique columns (Josh Berkus <josh@agliodbs.com>) |
Ответы |
Re: multi column foreign key for implicitly unique columns
|
Список | pgsql-sql |
On 8/18/2004 2:55 PM, Josh Berkus wrote: > Jan, >> >> If a.x is unique, then (b.x, b.y) references (a.x, a.y) is only ensuring >> that the redundant copy of y in b.y stays in sync with a.y. > > So? What's denormalized about that? His other choice is to use a trigger. Because the value in b.y is redundant. b.x->a.x->a.y is exactly the same value and he even wants to ensure this with theconstraint. Jan > > What he's trying to do is ensure that the class selected for the FK > class_name, field_name relates to the same class_name in objects. > -- #======================================================================# # It's easier to get forgiveness for being wrong than for being right. # # Let's break this rule - forgive me. # #================================================== JanWieck@Yahoo.com #
В списке pgsql-sql по дате отправления: