pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
To: Michael Paquier <michael@paquier.xyz>
To: digoal@126.com
To: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #15565: truncate bug with tables which have temp table inherited
Date: Tue, 25 Dec 2018 09:52:55 +0900
Message-ID: <c0bd4ae3-9fa2-bf15-5f32-7cd2910ec5fd@lab.ntt.co.jp> (raw)
In-Reply-To: <20181225004545.GB2334@paquier.xyz>
References: <15565-ce67a48d0244436a@postgresql.org>
	<20181225004545.GB2334@paquier.xyz>

On 2018/12/25 9:45, Michael Paquier wrote:
> On Mon, Dec 24, 2018 at 09:17:46AM +0000, PG Bug reporting form wrote:
>> create table public.a (id int);
>> create temp table a (like public.a) inherits(public.a);
> 
> This issue is way older than 11.
> 
> A couple of months ago there has been a discussion about mixing
> temporary and permanent tables in a partition tree:
> https://www.postgresql.org/message-id/CAKJS1f94Ojk0og9GMkRHGt8wHTW=ijq5KzJKuoBoqWLwSVwGmw@mail.gmail...
> 
> The conclusion of this time was that we don't want to allow mixing
> relations with different persistencies in the same tree for
> partitions because those rely on relation cache lookups for their
> description (PartitionDesc), however inheritance trees have been able
> to accidently work this way for a long time.  This shares a little bit
> of history with this report as partition trees and inheritance share
> the same lookups at pg_inherits.
> 
> So there could be an argument to restrict the definition of
> inheritance trees with trees mixing relation persistencies.
> 
> It is hard to say as well that truncate silently bypasses the
> truncation of a temporary relation from another session if a given
> session wants to truncate a whole tree.

Hmm, why don't we just ignore them like queries do?

Thanks,
Amit





view thread (16+ messages)  latest in thread

Message-ID: <c0bd4ae3-9fa2-bf15-5f32-7cd2910ec5fd@lab.ntt.co.jp>
Permalink:  ../c0bd4ae3-9fa2-bf15-5f32-7cd2910ec5fd@lab.ntt.co.jp/
Also on:    postgresql.org/message-id/c0bd4ae3-9fa2-bf15-5f32-7cd2910ec5fd@lab.ntt.co.jp

 · 

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-bugs@postgresql.org
  Cc: Langote_Amit_f8@lab.ntt.co.jp, michael@paquier.xyz, digoal@126.com, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #15565: truncate bug with tables which have temp table inherited
  In-Reply-To: <c0bd4ae3-9fa2-bf15-5f32-7cd2910ec5fd@lab.ntt.co.jp>

* 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