Re: backend crash on DELETE, reproducible locally
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Ondřej Bouda <obouda@email.cz>
Cc: Alvaro Herrera <alvherre@2ndquadrant.com>,
pgsql-hackers@lists.postgresql.org, pgsql-general@lists.postgresql.org
Date: 2018-11-06T21:03:35Z
Lists: pgsql-hackers, pgsql-general
=?UTF-8?Q?Ond=c5=99ej_Bouda?= <obouda@email.cz> writes:
>>> Hm, what are the data types of those columns?
> scheduletemplate_id bigint NOT NULL,
> period_day smallint NOT NULL,
> timerange timerange NOT NULL,
OK, so here's a minimal reproducer:
drop table schedulecard;
create table schedulecard (
scheduletemplate_id bigint NOT NULL,
period_day smallint NOT NULL
);
CREATE INDEX schedulecard_overlap_idx
ON schedulecard USING gist
(scheduletemplate_id, (period_day::integer % 7));
insert into schedulecard values(12, 1);
update schedulecard set period_day = period_day + 7;
Interestingly, it doesn't crash if I change the index type to btree,
which I was not expecting because the crashing code seems pretty
independent of the index type.
Haven't traced further than that yet.
regards, tom lane
Commits
-
Disable recheck_on_update optimization to avoid crashes.
- 05f84605dbeb 11.1 landed
- 5d28c9bd73e2 12.0 landed
-
Allow HOT updates for some expression indexes
- c203d6cf81b4 11.0 cited