diff options
author | unknown <bell@sanja.is.com.ua> | 2002-09-28 18:34:56 +0300 |
---|---|---|
committer | unknown <bell@sanja.is.com.ua> | 2002-09-28 18:34:56 +0300 |
commit | c9a2b58986635015b3f3867999ef3fafa2bd2728 (patch) | |
tree | 6fcd2ba5039822ee13c52903e85f243887bac5ba /mysql-test/r | |
parent | da891a571e49804e3743bf2776bcf2648a4832da (diff) | |
download | mariadb-git-c9a2b58986635015b3f3867999ef3fafa2bd2728.tar.gz |
fixed bug in string & date types with group function in subselect
mysql-test/r/subselect.result:
test suite of string & date types with group function in subselects
mysql-test/t/subselect.test:
test suite of string & date types with group function in subselects
sql/item_subselect.cc:
fixed bug in string type with group function
sql/item_subselect.h:
fixed bug in string type with group function
sql/sql_class.cc:
fixed bug in date type with group function
Diffstat (limited to 'mysql-test/r')
-rw-r--r-- | mysql-test/r/subselect.result | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/mysql-test/r/subselect.result b/mysql-test/r/subselect.result index 54528f58697..5a96cc08cbf 100644 --- a/mysql-test/r/subselect.result +++ b/mysql-test/r/subselect.result @@ -131,4 +131,20 @@ patient_uq clinic_uq 1 1 1 2 2 2 +drop table if exists t1,t2,t3; +CREATE TABLE t3 (a varchar(20),b char(1) NOT NULL default '0'); +INSERT INTO t3 VALUES ('W','a'),('A','c'),('J','b'); +CREATE TABLE t2 (a varchar(20),b int NOT NULL default '0'); +INSERT INTO t2 VALUES ('W','1'),('A','3'),('J','2'); +CREATE TABLE t1 (a varchar(20),b date NOT NULL default '0000-00-00'); +INSERT INTO t1 VALUES ('W','1732-02-22'),('A','1735-10-30'),('J','1743-04-13'); +SELECT * FROM t1 WHERE b = (SELECT MIN(b) FROM t1); +a b +W 1732-02-22 +SELECT * FROM t2 WHERE b = (SELECT MIN(b) FROM t2); +a b +W 1 +SELECT * FROM t3 WHERE b = (SELECT MIN(b) FROM t3); +a b +W a drop table t1,t2,t3,t4,t5,attend,clinic; |