Re: BUG #15720: `executor could not find named tuplestore ABC` in AFTER DELETE trigger referencing OLD TABLE as ABC
Thomas Munro <thomas.munro@gmail.com>
From: Thomas Munro <thomas.munro@gmail.com>
To: jason.madden@nextthought.com, PostgreSQL mailing lists <pgsql-bugs@lists.postgresql.org>
Date: 2019-03-29T10:12:47Z
Lists: 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
Commits
-
Pass QueryEnvironment down to EvalPlanQual's EState.
- 72b526779a93 10.10 landed
- 9509173d2430 11.5 landed
- abbb2e143213 12.0 landed
- f5825853e3af 13.0 landed