Re: Proposal for syntax to support creation of partition tables when creating parent table

From: Amit Langote <amitlangote09(at)gmail(dot)com>
To: Ahsan Hadi <ahsan(dot)hadi(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Muhammad Usama <m(dot)usama(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, movead(dot)li(at)highgo(dot)ca
Subject: Re: Proposal for syntax to support creation of partition tables when creating parent table
Date: 2019-09-26 07:33:17
Message-ID: CA+HiwqE5r=hfvjxBagkAstwiFfrfbqwtbU_Y_T5_1pgQGFLpjw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Ahsan, Usama

Thanks for starting work on this.

On Thu, Sep 26, 2019 at 3:46 AM Ahsan Hadi <ahsan(dot)hadi(at)gmail(dot)com> wrote:
> On Wed, Sep 25, 2019 at 8:53 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> As Fabien noted, there's been some related discussion about this
>> area, but nobody was advocating a solution of this particular shape.
>
> The thread that Usama mentioned in his email is creating auto-partitions just for HASH partitions, this is trying to do similar for all types of partitions.

I agree that this proposal makes life easier for developers familiar
with the partitioning syntax and features of other databases.
However, it adds little functionality over what users can already do,
even though today it takes multiple commands rather than just one.
The problem is that the syntax proposed here is still verbose because
users still have to spell out all the partition bounds by themselves.

The focus of the other thread, as I understand it, is to implement the
functionality to get the same thing done (create many partitions in
one command) in much less verbose manner. Fabien started the
discussion for hash partitioning because the interface for it seems
straightforward -- just specify the number of partitions and that many
partitions would get created without having to actually specify
modulus/remainder for each. Since the underlying functionality
wouldn't be too different for other partitioning methods, we would
only have to come up with a suitable interface.

Thanks,
Amit

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Masahiko Sawada 2019-09-26 08:14:44 pg_wal/RECOVERYHISTORY file remains after archive recovery
Previous Message Michael Paquier 2019-09-26 07:23:51 Re: Refactoring of connection with password prompt loop for frontends