Re: BUG #15720: `executor could not find named tuplestore ABC` inAFTER DELETE trigger referencing OLD TABLE as ABC - Mailing list pgsql-bugs

From Thomas Munro
Subject Re: BUG #15720: `executor could not find named tuplestore ABC` inAFTER DELETE trigger referencing OLD TABLE as ABC
Date
Msg-id CA+hUKGJbSd1fxUXwbV2Cvf_wE4gL9vWO3B38FB+1R_j7MzQ9hA@mail.gmail.com
Whole thread Raw
In response to BUG #15720: `executor could not find named tuplestore ABC` in AFTER DELETE trigger referencing OLD TABLE as ABC  (PG Bug reporting form <noreply@postgresql.org>)
Responses Re: BUG #15720: `executor could not find named tuplestore ABC` inAFTER DELETE trigger referencing OLD TABLE as ABC  (Jason Madden <jason.madden@nextthought.com>)
List pgsql-bugs
On Fri, Mar 29, 2019 at 4:49 AM PG Bug reporting form
<noreply@postgresql.org> wrote:
> SQL failure calling: SELECT * FROM wip_upload_finish(...)
> ...
> Caused by: org.postgresql.util.PSQLException: ERROR: executor could not find
> named tuplestore "updated_positions"
>   Where: SQL statement "UPDATE w_instances pi
>     SET last_modified = NOW()
>     FROM updated_positions up
>     WHERE pi.object_id = up.p_instance_id"
> PL/pgSQL function wip_update_AC_trigger_func() line 24 at SQL statement
> SQL statement "
>       DELETE FROM wip
>       WHERE p_instance_id = (
>         SELECT object_id
>         FROM w_instances
>         WHERE c1 = $1 and c2 = $2
>       )
>     "

Hi,

I haven't had time to look into this properly yet but a couple of
ideas occurred to me just from the description: I wonder if there is a
rare case of row movement in your workload (ie an update that moves a
row from one partition to another), and we have a bug in the
transition table code in that path.  Then again you said you reran the
job and it worked, so unless the data that drives that jobs changed
underneath it, that might not work.  Or perhaps some combination of ON
CONFLICT, partitions and transition tables is going awry...  What does
wip_upload_finish() do?

-- 
Thomas Munro
https://enterprisedb.com



pgsql-bugs by date:

Previous
From: PG Bug reporting form
Date:
Subject: BUG #15723: Export fails 'worker process died unexpectedly' but no error in pg_dump
Next
From: Stepan Yankevych
Date:
Subject: Can create foreign table as parition