1
0
mirror of https://github.com/MariaDB/server.git synced 2026-10-23 18:49:29 +03:00
Files
Dave Gosselin b51d2f12bc MDEV-41211 Federated multi-table DELETE keeps a const table row
A multi-table DELETE on a FEDERATED or FederatedX table went wrong
when a primary key lookup made the target a const table.  The
optimizer reads a const table's row through index_read_idx_map(),
whose default implementation ends the index scan and frees the result
set.  The server asks for the row's position later, during execution,
so the saved position was empty.  FederatedX skipped the row and
FEDERATED crashed in rnd_pos().

Both engines now override index_read_idx_map() so that the lookup
leaves its result set open, as index_read() does.  position() then
records a valid position, and the result set is freed at the end of
the statement.  FEDERATED's reset() now also clears stored_result,
which otherwise pointed at a freed result set and was freed again
when the table was closed.

Tests include a multitable UPDATE with a const target, which crashed
both engines before the fix.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-02 22:10:40 +02:00
..
2026-08-19 08:40:05 +02:00
2024-12-02 11:35:34 +02:00
2026-08-30 17:39:50 +02:00
2026-08-19 08:40:05 +02:00
2026-08-19 08:40:05 +02:00
2026-08-19 08:40:05 +02:00
2026-08-19 08:40:05 +02:00
2026-08-19 08:40:05 +02:00
2026-06-15 12:50:45 +02:00
2026-08-19 08:40:05 +02:00
2026-08-30 17:39:50 +02:00
2024-07-08 22:40:16 +02:00
2024-12-02 11:35:34 +02:00
2026-07-28 13:14:38 +02:00
2024-06-24 13:09:47 +03:00