-
-
Notifications
You must be signed in to change notification settings - Fork 141
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(Tianmu) Fix assertion errors caused by syntax optimization of the…
… tianmu engine (#669) Cause of the problem: The tianmu engine created join objects in syntax optimization, but did not explain them Modify Scheme: Release the join object after use
- Loading branch information
1 parent
47e8843
commit 0d0fcaf
Showing
3 changed files
with
98 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# | ||
# Fix assertion errors caused by syntax optimization of the tianmu engine #669 | ||
# | ||
use test; | ||
create table t11 (a int NOT NULL, b int, primary key (a))ENGINE=TIANMU; | ||
create table t12 (a int NOT NULL, b int, primary key (a))ENGINE=TIANMU; | ||
create table t2 (a int NOT NULL, b int, primary key (a))ENGINE=TIANMU; | ||
insert into t11 values (0, 10),(1, 11),(2, 12); | ||
insert into t12 values (33, 10),(0, 11),(2, 12); | ||
insert into t2 values (1, 21),(2, 12),(3, 23); | ||
delete from t11 where t11.b not in (select b from t2 where t11.a < t2.a); | ||
drop table t11,t12,t2; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--source include/have_tianmu.inc | ||
|
||
--echo # | ||
--echo # Fix assertion errors caused by syntax optimization of the tianmu engine #669 | ||
--echo # | ||
|
||
use test; | ||
create table t11 (a int NOT NULL, b int, primary key (a))ENGINE=TIANMU; | ||
create table t12 (a int NOT NULL, b int, primary key (a))ENGINE=TIANMU; | ||
create table t2 (a int NOT NULL, b int, primary key (a))ENGINE=TIANMU; | ||
insert into t11 values (0, 10),(1, 11),(2, 12); | ||
insert into t12 values (33, 10),(0, 11),(2, 12); | ||
insert into t2 values (1, 21),(2, 12),(3, 23); | ||
|
||
delete from t11 where t11.b not in (select b from t2 where t11.a < t2.a); | ||
|
||
drop table t11,t12,t2; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters