From: | David Fetter <david(at)fetter(dot)org> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Robert Haas <robertmhaas(at)gmail(dot)com>, Nikhil Sontakke <nikhil(dot)sontakke(at)enterprisedb(dot)com>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Jerry Sievers <gsievers19(at)comcast(dot)net>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Check constraints on partition parents only? |
Date: | 2011-07-26 15:51:32 |
Message-ID: | 20110726155132.GB18160@fetter.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, Jul 26, 2011 at 10:51:58AM -0400, Tom Lane wrote:
> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> > On Tue, Jul 26, 2011 at 4:12 AM, Nikhil Sontakke
> > <nikhil(dot)sontakke(at)enterprisedb(dot)com> wrote:
> >> Hmmm, but then it does open up the possibility of naive users shooting
> >> themselves in the foot. It can be easy to conjure up a
> >> parent-only-constraint that does not gel too well with its children. And
> >> that's precisely why this feature was added in the first place..
>
> > Yeah, but I think we need to take that chance. At the very least, we
> > need to support the equivalent of a non-inherited CHECK (false) on
> > parent tables.
>
> No, the right solution is to invent an actual concept of partitioned
> tables, not to keep adding ever-weirder frammishes to inheritance so
> that it can continue to provide an awkward, poorly-performing emulation
> of them.
Other SQL engines have partitions of types list, range and hash, and
some can sub-partition. I'm thinking it might be easiest to do the
first before adding layers of partition structure, although we should
probably bear in mind that such layers will eventually exist.
Does the wiki on this need updating?
http://wiki.postgresql.org/wiki/Table_partitioning
Cheers,
David.
--
David Fetter <david(at)fetter(dot)org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david(dot)fetter(at)gmail(dot)com
iCal: webcal://www.tripit.com/feed/ical/people/david74/tripit.ics
Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate
From | Date | Subject | |
---|---|---|---|
Next Message | Noah Misch | 2011-07-26 16:04:40 | Re: Another issue with invalid XML values |
Previous Message | Pavan Deolasee | 2011-07-26 15:40:36 | Re: write scalability |