Re: [PATCH] Support for foreign keys with arrays
Noah Misch <noah@leadboat.com>
From: Noah Misch <noah@leadboat.com>
To: Simon Riggs <simon@2ndQuadrant.com>
Cc: Marco Nenciarini <marco.nenciarini@2ndquadrant.it>, Gabriele Bartolini <gabriele.bartolini@2ndquadrant.it>, PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2012-01-23T02:30:45Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Allow LEAKPROOF functions for better performance of security views.
- cd30728fb2ed 9.2.0 cited
-
Improve labeling of pg_test_fsync open_sync test output.
- 2bbd88f8f841 9.2.0 cited
On Sun, Jan 22, 2012 at 09:06:49PM +0000, Simon Riggs wrote: > On Sat, Jan 21, 2012 at 8:42 PM, Noah Misch <noah@leadboat.com> wrote: > > > You currently forbid multi-column EACH FKs. ?I agree that we should allow only > > one array column per FK; with more, the set of required PK rows would be > > something like the Cartesian product of the elements of array columns. > > However, there are no definitional problems, at least for NO ACTION, around a > > FK constraint having one array column and N scalar columns. ?Whether or not > > you implement that now, let's choose a table_constraint syntax leaving that > > opportunity open. ?How about: > > ? ? ? ?FOREIGN KEY(col_a, EACH col_b, col_c) REFERENCES pktable (a, b, c) > > > I don't think we should be trying to cover every possible combination > of arrays, non-arrays and all the various options. The number of > combinations is making this patch larger than it needs to be and as a > result endangers its being committed in this release just on committer > time to cope with the complexity. We have a matter of weeks to get > this rock solid. > > Yes, lets keep syntax open for future additions, but lets please > focus/edit this down to a solid, useful patch for 9.2. +1. Let's change the syntax to leave that door open but not use the flexibility at this time.