diff options
author | unknown <monty@mysql.com> | 2003-12-15 17:58:15 +0200 |
---|---|---|
committer | unknown <monty@mysql.com> | 2003-12-15 17:58:15 +0200 |
commit | ec2e2c3af6f73b4d0a734510bc6ba74d2bb30e8c (patch) | |
tree | c239203a39c21349557d871ff1f29dd16ab0a5bc /mysql-test | |
parent | 8bc3575eebe7110466ef4fb0250fe7bffe48c9ee (diff) | |
download | mariadb-git-ec2e2c3af6f73b4d0a734510bc6ba74d2bb30e8c.tar.gz |
Added missing timeout function for named pipes and shared memory (fixes core dump on windows)
Signed auto_increment keys for HASH tables (like for MyISAM tables in 4.0)
nitialize system_charset_info() early. Fixes core dump when starting windows service
heap/hp_hash.c:
Signed auto_increment keys for HASH tables (like for MyISAM tables in 4.0)
mysql-test/r/create.result:
More test for type returned by if_null()
mysql-test/t/create.test:
More test for type returned by if_null()
sql/field.h:
Remove not needed functions
sql/item.cc:
Use normal field create function instead of special functions just made for tmp_table_field_from_field_type
sql/mysqld.cc:
Initialize system_charset_info() early. Fixes core dump when starting windows service
vio/vio.c:
Added missing timeouts for named pipes and shared memory (fixes core dump on windows)
vio/vio_priv.h:
Added missing timeout function for named pipes and shared memory (fixes core dump on windows)
vio/viosocket.c:
Added missing timeout function for named pipes and shared memory (fixes core dump on windows)
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/create.result | 22 | ||||
-rw-r--r-- | mysql-test/t/create.test | 10 |
2 files changed, 30 insertions, 2 deletions
diff --git a/mysql-test/r/create.result b/mysql-test/r/create.result index 2f61b4838ee..6160dd88fa5 100644 --- a/mysql-test/r/create.result +++ b/mysql-test/r/create.result @@ -407,6 +407,28 @@ a b c d e f g h dd 1 -7 7 2000-01-01 b 2000-01-01 00:00:00 05:04:03 yet another binary data 02:00:00 2 -2 2 1825-12-14 a 2003-01-01 03:02:01 04:03:02 binary data 02:00:00 drop table t1, t2; +create table t1 (a tinyint, b smallint, c mediumint, d int, e bigint, f float(3,2), g double(4,3), h decimal(5,4), i year, j date, k timestamp, l datetime, m enum('a','b'), n set('a','b'), o char(10)); +create table t2 select ifnull(a,a), ifnull(b,b), ifnull(c,c), ifnull(d,d), ifnull(e,e), ifnull(f,f), ifnull(g,g), ifnull(h,h), ifnull(i,i), ifnull(j,j), ifnull(k,k), ifnull(l,l), ifnull(m,m), ifnull(n,n), ifnull(o,o) from t1; +show create table t2; +Table Create Table +t2 CREATE TABLE `t2` ( + `ifnull(a,a)` tinyint(4) default NULL, + `ifnull(b,b)` smallint(6) default NULL, + `ifnull(c,c)` mediumint(9) default NULL, + `ifnull(d,d)` int(11) default NULL, + `ifnull(e,e)` bigint(20) default NULL, + `ifnull(f,f)` float(3,2) default NULL, + `ifnull(g,g)` double(4,3) default NULL, + `ifnull(h,h)` decimal(5,4) default NULL, + `ifnull(i,i)` year(4) default NULL, + `ifnull(j,j)` date default NULL, + `ifnull(k,k)` datetime NOT NULL default '0000-00-00 00:00:00', + `ifnull(l,l)` datetime default NULL, + `ifnull(m,m)` char(1) default NULL, + `ifnull(n,n)` char(3) default NULL, + `ifnull(o,o)` char(10) default NULL +) TYPE=MyISAM DEFAULT CHARSET=latin1 +drop table t1,t2; create table t1(str varchar(10) default 'def',strnull varchar(10),intg int default '10',rel double default '3.14'); insert into t1 values ('','',0,0.0); describe t1; diff --git a/mysql-test/t/create.test b/mysql-test/t/create.test index 54166c3b0dc..23d7cc8c347 100644 --- a/mysql-test/t/create.test +++ b/mysql-test/t/create.test @@ -318,11 +318,17 @@ select addtime(cast('1:0:0' as time),cast('1:0:0' as time)) as dd from t1; explain t2; - select * from t2; - drop table t1, t2; +create table t1 (a tinyint, b smallint, c mediumint, d int, e bigint, f float(3,2), g double(4,3), h decimal(5,4), i year, j date, k timestamp, l datetime, m enum('a','b'), n set('a','b'), o char(10)); +create table t2 select ifnull(a,a), ifnull(b,b), ifnull(c,c), ifnull(d,d), ifnull(e,e), ifnull(f,f), ifnull(g,g), ifnull(h,h), ifnull(i,i), ifnull(j,j), ifnull(k,k), ifnull(l,l), ifnull(m,m), ifnull(n,n), ifnull(o,o) from t1; +show create table t2; +drop table t1,t2; + +# +# Test of default() +# create table t1(str varchar(10) default 'def',strnull varchar(10),intg int default '10',rel double default '3.14'); insert into t1 values ('','',0,0.0); describe t1; |