summaryrefslogtreecommitdiff
path: root/mysql-test/t/derived.test
diff options
context:
space:
mode:
authorunknown <bell@sanja.is.com.ua>2004-01-17 15:28:20 +0200
committerunknown <bell@sanja.is.com.ua>2004-01-17 15:28:20 +0200
commitd63d204c07563050d99f16a9ff35e2c1e93a9d05 (patch)
treeffcdb30fc755e4df6f306baa40464c4f0071fd3d /mysql-test/t/derived.test
parent6eaa5c3a66adc7cbe152a8791b3ad560c3a936f5 (diff)
downloadmariadb-git-d63d204c07563050d99f16a9ff35e2c1e93a9d05.tar.gz
new test added
test fixed
Diffstat (limited to 'mysql-test/t/derived.test')
-rw-r--r--mysql-test/t/derived.test5
1 files changed, 3 insertions, 2 deletions
diff --git a/mysql-test/t/derived.test b/mysql-test/t/derived.test
index bb61dab6d74..8de95b4b600 100644
--- a/mysql-test/t/derived.test
+++ b/mysql-test/t/derived.test
@@ -35,6 +35,7 @@ select a from (select 1 as a) as b;
select 1 from (select 1) as a;
select * from (select * from t1 union select * from t1) a;
select * from (select * from t1 union all select * from t1) a;
+select * from (select * from t1 union all select * from t1 limit 2) a;
explain select * from (select * from t1 union select * from t1) a;
explain select * from (select * from t1 union all select * from t1) a;
CREATE TABLE t2 (a int not null);
@@ -154,13 +155,13 @@ CREATE TABLE t2 (
PARID int(11) default NULL,
UNIQUE KEY t2_ID_IDX (ID),
KEY t2_PARID_IDX (PARID)
-) TYPE=MyISAM DEFAULT CHARSET=latin1;
+) engine=MyISAM DEFAULT CHARSET=latin1;
INSERT INTO t2 VALUES (1000,0),(1001,0),(1002,0),(1003,0),(1008,1),(1009,1),(1010,1),(1011,1),(1016,2);
CREATE TABLE t3 (
ID int(11) default NULL,
DATA decimal(10,2) default NULL,
UNIQUE KEY t3_ID_IDX (ID)
-) TYPE=MyISAM DEFAULT CHARSET=latin1;
+) engine=MyISAM DEFAULT CHARSET=latin1;
INSERT INTO t3 VALUES (1000,0.00),(1001,0.25),(1002,0.50),(1003,0.75),(1008,1.00),(1009,1.25),(1010,1.50),(1011,1.75);
select 497, TMP.ID, NULL from (select 497 as ID, MAX(t3.DATA) as DATA from t1 join t2 on (t1.ObjectID = t2.ID) join t3 on (t1.ObjectID = t3.ID) group by t2.ParID order by DATA DESC) as TMP;
drop table t1, t2, t3;