mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 11:27:39 +02:00
fixed union types merging and table related metadata (BUG#8824)
mysql-test/r/func_group.result: new result mysql-test/r/metadata.result: new result test of metadata of variables, unions and derived tables mysql-test/r/union.result: new results test of union of enum mysql-test/t/metadata.test: test of metadata of variables, unions and derived tables mysql-test/t/union.test: test of union of enum sql/field.cc: Field type merging rules added Fixed table name/alias returting for field made from temporary tables sql/field.h: removed unned field type reporting sql/item.cc: fixed bug in NEW_DATE type field creartion replaced mechanism of merging types of UNION sql/item.h: replaced mechanism of merging types of UNION sql/item_func.h: new item type to make correct field type detection possible sql/item_subselect.cc: added table name parameter to prepare() to show right table alias for derived tables sql/sql_derived.cc: added table name parameter to prepare() to show right table alias for derived tables sql/sql_lex.h: added table name parameter to prepare() to show right table alias for derived tables sql/sql_parse.cc: made function for enum/set pack length calculation sql/sql_prepare.cc: added table name parameter to prepare() to show right table alias for derived tables sql/sql_select.cc: new temporary table field creation by Item_type_holder fixed table alias for temporary table sql/sql_union.cc: added table name parameter to prepare() to show right table alias for derived tables
This commit is contained in:
parent
98eecc7b35
commit
5a42525027
17 changed files with 1169 additions and 422 deletions
|
|
@ -747,7 +747,7 @@ insert into t1 values (now());
|
|||
create table t2 select f2 from (select max(now()) f2 from t1) a;
|
||||
show columns from t2;
|
||||
Field Type Null Key Default Extra
|
||||
f2 datetime 0000-00-00 00:00:00
|
||||
f2 datetime YES NULL
|
||||
drop table t2;
|
||||
create table t2 select f2 from (select now() f2 from t1) a;
|
||||
show columns from t2;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue