Commit 5331ad52 authored by unknown's avatar unknown
Browse files

Merge jamppa@bk-internal.mysql.com:/home/bk/mysql-5.0

into  a193-229-222-105.elisa-laajakaista.fi:/home/jani/mysql-5.0

parents 59de72a2 3f09d4b2
Loading
Loading
Loading
Loading
+10 −3
Original line number Diff line number Diff line
@@ -794,10 +794,17 @@ select f1 from t1 where makedate(2006,2) between date(f1) and date(f3);
f1
2006-01-02
drop table t1;
select now() - now() + 0, curtime() - curtime() + 0, 
create table t1 select now() - now(), curtime() - curtime(), 
sec_to_time(1) + 0, from_unixtime(1) + 0;
now() - now() + 0	curtime() - curtime() + 0	sec_to_time(1) + 0	from_unixtime(1) + 0
0.000000	0.000000	1.000000	19700101030001.000000
show create table t1;
Table	Create Table
t1	CREATE TABLE `t1` (
  `now() - now()` double(23,6) NOT NULL default '0.000000',
  `curtime() - curtime()` double(23,6) NOT NULL default '0.000000',
  `sec_to_time(1) + 0` double(23,6) default NULL,
  `from_unixtime(1) + 0` double(23,6) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
explain extended select timestampdiff(SQL_TSI_WEEK, '2001-02-01', '2001-05-01') as a1,
timestampdiff(SQL_TSI_FRAC_SECOND, '2001-02-01 12:59:59.120000', '2001-05-01 12:58:58.119999') as a2;
id	select_type	table	type	possible_keys	key	key_len	ref	rows	Extra
+22 −1
Original line number Diff line number Diff line
drop table if exists t1;
drop table if exists t1,t2;
CREATE TABLE t1 (
gesuchnr int(11) DEFAULT '0' NOT NULL,
benutzer_id int(11) DEFAULT '0' NOT NULL,
@@ -31,3 +31,24 @@ SELECT * from t1 ORDER BY i;
i	j	k
3	1	42
17	2	24
CREATE TABLE t2 (a INT(11) NOT NULL,
b INT(11) NOT NULL,
c INT(11) NOT NULL,
x TEXT,
y TEXT,
z TEXT,
id INT(10) unsigned NOT NULL AUTO_INCREMENT,
i INT(11) DEFAULT NULL,
PRIMARY KEY (id),
UNIQUE KEY a (a,b,c)
) ENGINE=ndbcluster;
REPLACE INTO t2 (a,b,c,x,y,z,i) VALUES (1,1,1,'a','a','a',1),(1,1,1,'b','b','b',2), (1,1,1,'c','c','c',3);
SELECT * FROM t2 ORDER BY id;
a	b	c	x	y	z	id	i
1	1	1	c	c	c	3	3
REPLACE INTO t2(a,b,c,x,y,z,i) values (1,1,1,'a','a','a',1);
REPLACE INTO t2(a,b,c,x,y,z,i) values (1,1,1,'b','b','b',2);
SELECT * FROM t2 ORDER BY id;
a	b	c	x	y	z	id	i
1	1	1	b	b	b	5	2
DROP TABLE t2;
+4 −2
Original line number Diff line number Diff line
@@ -392,8 +392,10 @@ drop table t1;
# Bug #16546
# 

select now() - now() + 0, curtime() - curtime() + 0, 
create table t1 select now() - now(), curtime() - curtime(), 
                       sec_to_time(1) + 0, from_unixtime(1) + 0;
show create table t1;
drop table t1;

# End of 4.1 tests

+28 −2
Original line number Diff line number Diff line
@@ -6,7 +6,7 @@
#

--disable_warnings
drop table if exists t1;
drop table if exists t1,t2;
--enable_warnings

CREATE TABLE t1 (
@@ -27,6 +27,8 @@ replace into t1 (gesuchnr,benutzer_id) values (1,1);
select * from t1 order by gesuchnr;
drop table t1;

# End of 4.1 tests

# bug#17431
CREATE TABLE t1(i INT PRIMARY KEY AUTO_INCREMENT, 
                j INT, 
@@ -38,4 +40,28 @@ REPLACE INTO t1 (j,k) VALUES (1,42);
REPLACE INTO t1 (i,j) VALUES (17,2);
SELECT * from t1 ORDER BY i;

# End of 4.1 tests
# bug#19906
CREATE TABLE t2 (a INT(11) NOT NULL,
	         b INT(11) NOT NULL,
                 c INT(11) NOT NULL,
                 x TEXT,
                 y TEXT,
                 z TEXT,
                 id INT(10) unsigned NOT NULL AUTO_INCREMENT,
                 i INT(11) DEFAULT NULL,
                 PRIMARY KEY (id),
                 UNIQUE KEY a (a,b,c)
) ENGINE=ndbcluster;

REPLACE INTO t2 (a,b,c,x,y,z,i) VALUES (1,1,1,'a','a','a',1),(1,1,1,'b','b','b',2), (1,1,1,'c','c','c',3);

SELECT * FROM t2 ORDER BY id;

REPLACE INTO t2(a,b,c,x,y,z,i) values (1,1,1,'a','a','a',1);
REPLACE INTO t2(a,b,c,x,y,z,i) values (1,1,1,'b','b','b',2);

SELECT * FROM t2 ORDER BY id;

DROP TABLE t2;

+1 −1
Original line number Diff line number Diff line
@@ -1322,7 +1322,7 @@ TransporterRegistry::start_clients_thread()
	      else
	      {
		ndbout_c("Management server closed connection early. "
			 "It is probably being shut down (or has crashed). "
			 "It is probably being shut down (or has problems). "
			 "We will retry the connection.");
	      }
	    }
Loading