Re: BUG #15489: Segfault on DELETE
От
Amit Langote
Тема
Re: BUG #15489: Segfault on DELETE
Дата
Msg-id
0ff5c33e-43b9-d3e2-9f74-572b694b0ac1@lab.ntt.co.jp
Ответ на
Re: Re: BUG #15489: Segfault on DELETE (Frederico Costa Galvão)
Список
Дерево обсуждения
BUG #15489: Segfault on DELETE PG Bug reporting form <noreply@postgresql.org>
Re: BUG #15489: Segfault on DELETE Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: BUG #15489: Segfault on DELETE Michael Paquier <michael@paquier.xyz>
Re: Re: BUG #15489: Segfault on DELETE Frederico Costa Galvão<frederico.costa.galvao@gmail.com>
Re: BUG #15489: Segfault on DELETE Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: BUG #15489: Segfault on DELETE Kanwei Li <kanwei@gmail.com>
Re: BUG #15489: Segfault on DELETE Frederico Galvão <frederico.costa.galvao@gmail.com>
Re: BUG #15489: Segfault on DELETE Tom Lane <tgl@sss.pgh.pa.us>
Thanks Frederico for your reply. On 2018/11/08 10:10, Frederico Costa Galvão wrote: > I stumbled upon this issue yesterday, and trying to reduce and pinpoint > it, I managed to get to this: > > //start > CREATE TABLE a ( > id bigint > ); > > INSERT INTO a (id) VALUES (1); -- this id's value doesn't matter > > ALTER TABLE ONLY a > ADD CONSTRAINT a_pkey PRIMARY KEY (id); > > CREATE TABLE b ( > a_id bigint > ); > > ALTER TABLE ONLY b > ADD CONSTRAINT b_a_id_fkey FOREIGN KEY (a_id) REFERENCES a(id); > > ALTER TABLE a ADD x BOOLEAN NOT NULL DEFAULT FALSE; -- or TRUE, doesn't > matter There it is. These are similar steps as I'd used to track down a bug that's now fixed in 11.1. https://www.postgresql.org/message-id/9cb4aa1c-12ba-59c3-fd75-545fa90fb92f%40lab.ntt.co.jp The bug had to do with foreign key trigger not getting a proper representation of the tuple being deleted, considering the newly added column. > -- VACUUM FULL ANALYZE a; -- uncomment this to fix the bug Ah, VACUUM FULL will rewrite the tuples such that they're not hit by the aforementioned bug. So, if OP can tell that this is what happened in their case too, then 11.1 will have fixed the issue. Thanks, Amit
В списке pgsql-bugs по дате отправления
От: Thomas Munro
Дата: