Re: Moving child tables to partitions?

From: Keith Fiske <keith(dot)fiske(at)crunchydata(dot)com>
To: Wells Oliver <wells(dot)oliver(at)gmail(dot)com>
Cc: pgsql-admin <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Moving child tables to partitions?
Date: 2020-01-07 19:44:58
Message-ID: CAODZiv60=GLEH+z+zvz7HNrAKLaVkex0KV1yqT74VKe=wvoMiQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Tue, Jan 7, 2020 at 1:54 PM Wells Oliver <wells(dot)oliver(at)gmail(dot)com> wrote:

> Is this a possible thing? I'd like to consolidate some older child/parent
> style relationships into the newer partition style.
>
> --
> Wells Oliver
> wells(dot)oliver(at)gmail(dot)com <wellsoliver(at)gmail(dot)com>
>

Yes, this is certainly possible. Whether it's easy or complex really
depends on your original partitioning setup, though. I've got an initial
draft up for doing this sort of migration when using pg_partman. While some
of the steps use things specific to pg_partman, the overall process
should be the same for any migration. I'll be including the finalized doc
in my next release.

https://github.com/pgpartman/pg_partman/blob/migrate/doc/migrate_to_native.md

--
Keith Fiske
Senior Database Engineer
Crunchy Data - http://crunchydata.com

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Shrikant Bhende 2020-01-08 05:23:18 Re: Alter command getting stuck on a table
Previous Message Jerry Sievers 2020-01-07 19:04:19 Re: Alter command getting stuck on a table