diff options
author | unknown <monty@mashka.mysql.fi> | 2002-12-26 15:55:22 +0200 |
---|---|---|
committer | unknown <monty@mashka.mysql.fi> | 2002-12-26 15:55:22 +0200 |
commit | 9a54cc302c6be7971dc65f9654308152dde46df1 (patch) | |
tree | ef6694cd7850443a84092fad2ab87403436d801b | |
parent | 4d81fae0daeb4b12f316fadb0d76a780bb3efeee (diff) | |
download | mariadb-git-9a54cc302c6be7971dc65f9654308152dde46df1.tar.gz |
Test cleanup
mysql-test/r/case.result:
Removed unnecessary drop commands
mysql-test/t/case.test:
Removed unnecessary drop commands
-rw-r--r-- | mysql-test/r/case.result | 3 | ||||
-rw-r--r-- | mysql-test/t/case.test | 8 |
2 files changed, 7 insertions, 4 deletions
diff --git a/mysql-test/r/case.result b/mysql-test/r/case.result index 661ffa99f2c..4c16b375400 100644 --- a/mysql-test/r/case.result +++ b/mysql-test/r/case.result @@ -63,7 +63,6 @@ nothing 2 one 1 two 1 drop table t1; -drop table if exists t; create table t1 (row int not null, col int not null, val varchar(255) not null); insert into t1 values (1,1,'orange'),(1,2,'large'),(2,1,'yellow'),(2,2,'medium'),(3,1,'green'),(3,2,'small'); select max(case col when 1 then val else null end) as color from t1 group by row; @@ -71,4 +70,4 @@ color orange yellow green -drop table if exists t; +drop table t1; diff --git a/mysql-test/t/case.test b/mysql-test/t/case.test index b5a1a60f15b..3ba3a292c77 100644 --- a/mysql-test/t/case.test +++ b/mysql-test/t/case.test @@ -30,8 +30,12 @@ insert into t1 values(1),(2),(3),(4); select case a when 1 then 2 when 2 then 3 else 0 end as fcase, count(*) from t1 group by fcase; select case a when 1 then "one" when 2 then "two" else "nothing" end as fcase, count(*) from t1 group by fcase; drop table t1; -drop table if exists t1; + +# +# Test MAX(CASE ... ) that can return null +# + create table t1 (row int not null, col int not null, val varchar(255) not null); insert into t1 values (1,1,'orange'),(1,2,'large'),(2,1,'yellow'),(2,2,'medium'),(3,1,'green'),(3,2,'small'); select max(case col when 1 then val else null end) as color from t1 group by row; -drop table if exists t1; +drop table t1; |