mirror of
https://github.com/MariaDB/server.git
synced 2025-01-29 02:05:57 +01:00
Fix after previous cset: update test results
This commit is contained in:
parent
0df523d1f3
commit
42b928ca05
2 changed files with 19 additions and 0 deletions
|
@ -760,6 +760,23 @@ LEFT JOIN t2 AS SQ4_alias3 ON SQ4_alias3.f10
|
|||
GROUP BY field2;
|
||||
field2
|
||||
drop table t1, t2, t3;
|
||||
#
|
||||
# BUG#849763: Wrong result with second execution of prepared statement with semijoin + view
|
||||
#
|
||||
CREATE TABLE t1 ( c varchar(1)) engine=innodb;
|
||||
INSERT INTO t1 VALUES ('r');
|
||||
CREATE TABLE t2 ( a integer, b varchar(1), c varchar(1)) engine=innodb;
|
||||
INSERT INTO t2 VALUES (1,'r','r');
|
||||
CREATE OR REPLACE VIEW v1 AS SELECT * FROM t1;
|
||||
PREPARE st1 FROM 'SELECT * FROM t2 WHERE a = SOME (SELECT a FROM v1 WHERE v1.c = t2.c)';
|
||||
EXECUTE st1;
|
||||
a b c
|
||||
1 r r
|
||||
EXECUTE st1;
|
||||
a b c
|
||||
1 r r
|
||||
DROP VIEW v1;
|
||||
DROP TABLE t1, t2;
|
||||
set optimizer_switch=@subselect_sj2_tmp;
|
||||
set optimizer_switch=default;
|
||||
select @@optimizer_switch like '%materialization=on%';
|
||||
|
|
|
@ -2477,6 +2477,8 @@ void Item_in_subselect::fix_after_pullout(st_select_lex *new_parent, Item **ref)
|
|||
{
|
||||
left_expr->fix_after_pullout(new_parent, &left_expr);
|
||||
Item_subselect::fix_after_pullout(new_parent, ref);
|
||||
//psergey-todo: the above looks odd, why don't we 'aggregate' left_expr with
|
||||
//the rest?
|
||||
}
|
||||
|
||||
void Item_in_subselect::update_used_tables()
|
||||
|
|
Loading…
Add table
Reference in a new issue