pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Erik Wienhold <ewie@ewie.name>
To: Rakesh Nashine <nashine.rakesh@gmail.com>
To: pgsql-general@lists.postgresql.org
Subject: Re: How to remove the partition from table .
Date: Tue, 25 Oct 2022 13:09:25 +0200 (CEST)
Message-ID: <568082632.421153.1666696165054@office.mailbox.org> (raw)
In-Reply-To: <CAP_RtMRAH+my+Gye9f5eLVXRqXeGamFciHSmQv7bKdDoNgK7VA@mail.gmail.com>
References: <CAP_RtMRAH+my+Gye9f5eLVXRqXeGamFciHSmQv7bKdDoNgK7VA@mail.gmail.com>

> On 25/10/2022 12:47 CEST Rakesh Nashine <nashine.rakesh@gmail.com> wrote:
>
> We would like to remove the partition from one of the tables , although that
> partition has some business data. Now business doesn't need that partition
> any more .. How could we remove it? although they need the data .

Detach the partition:

https://www.postgresql.org/docs/15/sql-altertable.html#SQL-ALTERTABLE-DETACH-PARTITION

--
Erik





view thread (3+ messages)  latest in thread

Message-ID: <568082632.421153.1666696165054@office.mailbox.org>
Permalink:  ../568082632.421153.1666696165054@office.mailbox.org/
Also on:    postgresql.org/message-id/568082632.421153.1666696165054@office.mailbox.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: ewie@ewie.name, nashine.rakesh@gmail.com
  Subject: Re: How to remove the partition from table .
  In-Reply-To: <568082632.421153.1666696165054@office.mailbox.org>
  References: <CAP_RtMRAH+my+Gye9f5eLVXRqXeGamFciHSmQv7bKdDoNgK7VA@mail.gmail.com> <568082632.421153.1666696165054@office.mailbox.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox