Re: BUG #15565: truncate bug with tables which have temp table inherited
Amit Langote <langote_amit_f8@lab.ntt.co.jp>
From: Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
To: David Rowley <david.rowley@2ndquadrant.com>
Cc: digoal@126.com, pgsql-bugs@lists.postgresql.org,
PG Bug reporting form <noreply@postgresql.org>
Date: 2018-12-25T08:03:37Z
Lists: pgsql-bugs
Attachments
- truncate-ignore-other-session-temp-children-v2.patch (text/plain) patch v2
On 2018/12/25 16:27, David Rowley wrote: > On Tue, 25 Dec 2018 at 13:50, Amit Langote > <Langote_Amit_f8@lab.ntt.co.jp> wrote: >> I'm not sure if the error being shown is a bug, but maybe we could remove >> the error by making truncate do the same thing as select/update/delete, >> that is, ignore child tables that are temporary of tables of other >> sessions. Attached patch to do that. > > I glanced at this and was confused at where "newrelation" comes from > and also the single parameter heap_close(). It does not look like it > would compile. Sorry, that was pretty negligent of me. Here's the updated patch. Thanks, Amit
Commits
-
Ignore inherited temp relations from other sessions when truncating
- 1d7007671051 9.4.21 landed
- 0a323ae67699 9.5.16 landed
- 285abc8df4d7 9.6.12 landed
- d4486700b583 10.7 landed
- b30b9dce1f40 11.2 landed
- 1e504f01da11 12.0 landed