mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
MDEV-28578 Server crashes in Item_field::fix_outer_field after CREATE SELECT
same as MDEV-26412, but in CREATE...SELECT.
fix: apply 39feab3cd3
to create rule too.
This commit is contained in:
@ -770,4 +770,12 @@ create table t (a int);
|
|||||||
select 1 in (select count(*) from t t1 join (t t2 join t t3 on (t1.a != 0)));
|
select 1 in (select count(*) from t t1 join (t t2 join t t3 on (t1.a != 0)));
|
||||||
ERROR 42S22: Unknown column 't1.a' in 'on clause'
|
ERROR 42S22: Unknown column 't1.a' in 'on clause'
|
||||||
drop table t;
|
drop table t;
|
||||||
|
#
|
||||||
|
# MDEV-28578 Server crashes in Item_field::fix_outer_field after CREATE SELECT
|
||||||
|
#
|
||||||
|
create table t1 (i int) ;
|
||||||
|
create table t2 (j int) ;
|
||||||
|
create table t4 select * from t1 join t2 on (select t3.i);
|
||||||
|
ERROR 42S22: Unknown column 't3.i' in 'field list'
|
||||||
|
drop table t1, t2;
|
||||||
# End of 10.4 tests
|
# End of 10.4 tests
|
||||||
|
@ -638,4 +638,13 @@ create table t (a int);
|
|||||||
select 1 in (select count(*) from t t1 join (t t2 join t t3 on (t1.a != 0)));
|
select 1 in (select count(*) from t t1 join (t t2 join t t3 on (t1.a != 0)));
|
||||||
drop table t;
|
drop table t;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-28578 Server crashes in Item_field::fix_outer_field after CREATE SELECT
|
||||||
|
--echo #
|
||||||
|
create table t1 (i int) ;
|
||||||
|
create table t2 (j int) ;
|
||||||
|
--error ER_BAD_FIELD_ERROR
|
||||||
|
create table t4 select * from t1 join t2 on (select t3.i);
|
||||||
|
drop table t1, t2;
|
||||||
|
|
||||||
--echo # End of 10.4 tests
|
--echo # End of 10.4 tests
|
||||||
|
@ -2693,6 +2693,7 @@ create:
|
|||||||
lex->create_info.default_table_charset= NULL;
|
lex->create_info.default_table_charset= NULL;
|
||||||
lex->name= null_clex_str;
|
lex->name= null_clex_str;
|
||||||
lex->create_last_non_select_table= lex->last_table();
|
lex->create_last_non_select_table= lex->last_table();
|
||||||
|
lex->inc_select_stack_outer_barrier();
|
||||||
}
|
}
|
||||||
create_body
|
create_body
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user