Re: Range Partitioning behaviour - query

From: Venkata B Nagothi <nag1010(at)gmail(dot)com>
To: Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>
Cc: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Range Partitioning behaviour - query
Date: 2017-02-24 05:11:40
Message-ID: CAEyp7J9p6rb8eZSuh=vwL37e2MjHikBEu8G4_kfq1TxyHMLgvg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Feb 24, 2017 at 1:01 PM, Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp
> wrote:

> On 2017/02/24 10:38, David G. Johnston wrote:
> > On Thu, Feb 23, 2017 at 6:17 PM, Amit Langote <
> Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp
> >> wrote:
> >
> >> On 2017/02/24 8:38, Venkata B Nagothi wrote:
> >>> On Thu, Feb 23, 2017 at 3:14 PM, Amit Langote wrote:
> >>>> Upper bound of a range partition is an exclusive bound. A note was
> >> added
> >>>> recently to the CREATE TABLE page to make this clear.
> >>>>
> >>>> https://www.postgresql.org/docs/devel/static/sql-createtable.html
> >>>
> >>>
> >>> Thanks. Actually, my confusion was that the upper bound value would be
> >>> included when "TO" clause is used in the syntax.
> >>
> >> Hmm, TO sounds like it implies inclusive.
> >>
> >
> > ​I think most common usage of the word ends up being inclusive but the
> word
> > itself doesn't really care.​
> >
> > Dictionary.com has a good example:
> >
> > "We work from nine to five." - you leave at the beginning of the 5
> o'clock
> > hour (I'm going for casual usage here)
>
> Thanks for that example.
>
> One problem I've seen people mention is one of cognitive dissonance of
> having to define partition_y2013 as FROM ('2013-01-01') TO ('2014-01-01'),
> given that that's the only way to get what one needs. But we concluded
> that that's a reasonable compromise.
>

Agreed. I do see the similar approach adopted across other traditional
RDBMS products as well.

Regards,

Venkata B N
Database Consultant

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2017-02-24 05:11:43 Re: Should we cacheline align PGXACT?
Previous Message Amit Kapila 2017-02-24 05:03:25 Re: Enabling parallelism for queries coming from SQL or other PL functions