[MDEV-9477] delete_returning.test fails in mdev8646 tree Created: 2016-01-27  Updated: 2017-09-09  Resolved: 2016-01-27

Status: Closed
Project: MariaDB Server
Component/s: Optimizer
Affects Version/s: N/A
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: Sergei Petrunia Assignee: Sergei Petrunia
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
PartOf
is part of MDEV-8646 Re-engineer the code for post-join op... Closed
Relates
relates to MDEV-13776 mysqld got signal 11 on delete returning Closed
Sprint: 10.2.0-5

 Description   

delete_returning test fails in MDEV-8646 tree.

Crashing queries:

CREATE TABLE t1 (i1 int);
INSERT INTO t1 VALUES (1),(2);
CREATE TABLE t2 (i2 int);
INSERT INTO t2 VALUES (1),(2);
DELETE FROM t1 ORDER BY i1 RETURNING ( SELECT i2 FROM t2 );

The reason the last one crashes is that the execution code first calls:

JOIN::cleanup (this=0x7fff64065c68, full=true)

and then it calls

JOIN::exec (this=0x7fff64065c68)

that is, attempts to execute a join where it already did a cleanup.



 Comments   
Comment by Sergei Petrunia [ 2016-01-27 ]

The "exec-after-cleanup" can be observed on MariaDB 10.0, too. It doesn't crash, because in 10.0, a join can survive JOIN::exec() after JOIN::cleanup(full=true).

Comment by Sergei Petrunia [ 2016-01-27 ]

Pushed into bb-10.1-mdev8646 branch.

Generated at Thu Feb 08 07:34:58 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.