diff options
author | unknown <bell@laptop.sanja.is.com.ua> | 2003-08-23 13:29:38 +0300 |
---|---|---|
committer | unknown <bell@laptop.sanja.is.com.ua> | 2003-08-23 13:29:38 +0300 |
commit | 93afa26ea7c6206aca6d8dc3b25873f4d732b929 (patch) | |
tree | 53f4829d55971fc556fdf48ef0def5296d1b9f18 /mysql-test/t | |
parent | b4a45538dfc89868246bdb1bd6ec8a20eba666b1 (diff) | |
download | mariadb-git-93afa26ea7c6206aca6d8dc3b25873f4d732b929.tar.gz |
fixed bug of lack of fix_fields call (after merge bugfix (SCRUM))
fixed bug in Item_sum
fixed bug in dependence remover
after merge fix
mysql-test/r/subselect.result:
after merge fix
mysql-test/r/union.result:
new test
mysql-test/t/subselect.test:
after merge fix
mysql-test/t/union.test:
new test
sql/item.cc:
fixed returned value
sql/item.h:
fixed flag dropper
(I was not able to find Item whicj need more to be fix_fielded twice)
sql/item_subselect.h:
fixed initialisation
sql/item_sum.cc:
fixed absence of walk method of Item_sum
sql/item_sum.h:
fixed absence of walk method of Item_sum
sql/mysql_priv.h:
setup_fields reverter
sql/sql_base.cc:
setup_fields reverter
sql/sql_derived.cc:
fixed bug of lack of fix_fields call
sql/sql_union.cc:
fixed bug of lack of fix_fields call
Diffstat (limited to 'mysql-test/t')
-rw-r--r-- | mysql-test/t/subselect.test | 2 | ||||
-rw-r--r-- | mysql-test/t/union.test | 10 |
2 files changed, 11 insertions, 1 deletions
diff --git a/mysql-test/t/subselect.test b/mysql-test/t/subselect.test index e4813326b14..74f789395fc 100644 --- a/mysql-test/t/subselect.test +++ b/mysql-test/t/subselect.test @@ -900,7 +900,7 @@ insert into t1 values (1),(2),(3),(4); insert into t2 values (10),(20),(30),(40); insert into t3 values (1),(2),(10),(50); select a from t3 where t3.a in (select a from t1 where a <= 3 union select * from t2 where a <= 30); -drop table t1,t2; +drop table t1,t2,t3; # # correct ALL optimisation diff --git a/mysql-test/t/union.test b/mysql-test/t/union.test index 3506c713907..8f49f56b991 100644 --- a/mysql-test/t/union.test +++ b/mysql-test/t/union.test @@ -236,3 +236,13 @@ insert into t2 (group_name) values ('Group B'); insert into t3 (user_id, group_id) values (1,1); select 1 'is_in_group', a.user_name, c.group_name, b.id from t1 a, t3 b, t2 c where a.id = b.user_id and b.group_id = c.id UNION select 0 'is_in_group', a.user_name, c.group_name, null from t1 a, t2 c; drop table t1, t2, t3; + +# +# fix_fields problem +# +create table t1 (mat_id MEDIUMINT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY, matintnum CHAR(6) NOT NULL, test MEDIUMINT UNSIGNED NULL); +create table t2 (mat_id MEDIUMINT UNSIGNED NOT NULL, pla_id MEDIUMINT UNSIGNED NOT NULL); +insert into t1 values (NULL, 'a', 1), (NULL, 'b', 2), (NULL, 'c', 3), (NULL, 'd', 4), (NULL, 'e', 5), (NULL, 'f', 6), (NULL, 'g', 7), (NULL, 'h', 8), (NULL, 'i', 9); +insert into t2 values (1, 100), (1, 101), (1, 102), (2, 100), (2, 103), (2, 104), (3, 101), (3, 102), (3, 105); +SELECT mp.pla_id, MIN(m1.matintnum) AS matintnum FROM t2 mp INNER JOIN t1 m1 ON mp.mat_id=m1.mat_id GROUP BY mp.pla_id union SELECT 0, 0; +drop table t1, t2; |