pg.ddx.io pgsql-hackers@postgresql.org mailing list archive
help / color / mirror / Atom feed From: Tom Lane <tgl@sss.pgh.pa.us>
To: Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>
Cc: Amit Langote <amitlangote09@gmail.com>
Cc: Maksim Milyutin <m.milyutin@postgrespro.ru>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: Partitioned tables and relfilenode
Date: Tue, 11 Apr 2017 09:45:00 -0400
Message-ID: <28523.1491918300@sss.pgh.pa.us> (raw )
In-Reply-To: <062ab583-767d-9d08-5c7c-16b674a4c279@lab.ntt.co.jp >
References: <CA+HiwqFmrJGe4eid2EaqnCjjQxrAYR5hJfzc5Cz929WA9p=A+w@mail.gmail.com >
<20170331.155028.28878375.horiguchi.kyotaro@lab.ntt.co.jp >
<2dec1acb-6e2f-5aa5-0e26-fcc172ce9359@lab.ntt.co.jp >
<20170331.173326.212311140.horiguchi.kyotaro@lab.ntt.co.jp >
<CA+TgmobWCabQb6J72UC2TOsXwbWUFBL5C5OKGpiq3jhddutpbQ@mail.gmail.com >
<07595d66-bab8-2e24-438e-bacd20df52b5@lab.ntt.co.jp >
<062ab583-767d-9d08-5c7c-16b674a4c279@lab.ntt.co.jp >
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
Amit Langote <Langote_Amit_f8@lab.ntt.co.jp> writes:
> 2. DefineQueryRewrite() may try to scan a partitioned table in the case of
> converting a table to view, where we must make sure that the table being
> converted is empty. It's checked by scanning the heap, which we should
> not do for a partitioned table. Nor should we try to drop the storage
> once ready to make the table into a REKIND_VIEW relation (because all
> other checks passed okaying the conversion).
It looks like this patch intends to allow converting a partitioned table
to a view. I would lobby for refusing the command, instead. There is
no good reason to allow it, and it might well be a user error.
regards, tom lane
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
view thread (96+ messages) latest in thread
Message-ID: <28523.1491918300@sss.pgh.pa.us>
Permalink: ../28523.1491918300@sss.pgh.pa.us/
Also on: postgresql.org/message-id/28523.1491918300@sss.pgh.pa.us
copy link · copy postgr.es
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 using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, Langote_Amit_f8@lab.ntt.co.jp, robertmhaas@gmail.com, horiguchi.kyotaro@lab.ntt.co.jp, amitlangote09@gmail.com, m.milyutin@postgrespro.ru
Subject: Re: Partitioned tables and relfilenode
In-Reply-To: <28523.1491918300@sss.pgh.pa.us>
* 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