From: | Julien Rouhaud <rjuju123(at)gmail(dot)com> |
---|---|
To: | Fujii Masao <masao(dot)fujii(at)gmail(dot)com> |
Cc: | Amit Langote <amitlangote09(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: table partition and column default |
Date: | 2019-12-26 09:21:45 |
Message-ID: | CAOBaU_YoYP3NZQNxb_BOo474Ro5umEOa08i_tskrBxMwHZr0eQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Fuji-san,
On Thu, Dec 26, 2019 at 7:12 AM Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
>
> On Wed, Dec 25, 2019 at 5:47 PM Amit Langote <amitlangote09(at)gmail(dot)com> wrote:
> >
> > On Wed, Dec 25, 2019 at 5:40 PM Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
> > > On Wed, Dec 25, 2019 at 1:56 PM Amit Langote <amitlangote09(at)gmail(dot)com> wrote:
> > > > IIRC, there was some discussion about implementing a feature whereby
> > > > partition's default will used for an attribute if it's null even after
> > > > considering the parent table's default, that is, when no default value
> > > > is defined in the parent. The details are at toward the end of this
> > > > thread:
> > > >
> > > > https://www.postgresql.org/message-id/flat/578398af46350effe7111895a4856b87b02e000e.camel%402ndquadrant.com
> > >
> > > Thanks for pointing that thread!
> > >
> > > As you mentioned in that thread, I also think that this current
> > > behavior (maybe restriction) should be documented.
> > > What about adding the note like "a partition's default value is
> > > not applied when inserting a tuple through a partitioned table."
> > > into the document?
> >
> > Agreed.
> >
> > > Patch attached.
> >
> > Thanks for creating the patch, looks good to me.
>
> Thanks for reviewing the patch. Committed!
I saw that you only pushed it on master, shouldn't we backpatch it
down to pg10 as this is the declarative partitioning behavior since
the beginning?
From | Date | Subject | |
---|---|---|---|
Next Message | Julien Rouhaud | 2019-12-26 09:26:16 | Re: Expose lock group leader pid in pg_stat_activity |
Previous Message | Guillaume Lelarge | 2019-12-26 09:19:53 | Re: Expose lock group leader pid in pg_stat_activity |