Commit d467ad24 authored by unknown's avatar unknown
Browse files

Merge paul@bk-internal.mysql.com:/home/bk/mysql-4.1

into kite-hub.kitebird.com:/src/extern/MySQL/bk/mysql-4.1

parents bb538317 6829605c
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -68,3 +68,7 @@ Warnings:
Error	1259	ZLIB: Input data corrupted
Error	1256	Uncompressed data size too large; the maximum size is 1048576 (probably, length of uncompressed data was corrupted)
drop table t1;
set @@max_allowed_packet=1048576*100;
select length(compress(repeat('aaaaaaaaaa', 10000000)));
length(compress(repeat('aaaaaaaaaa', 10000000)))
97214
+4 −4
Original line number Diff line number Diff line
@@ -18,12 +18,12 @@ col5 enum('PENDING', 'ACTIVE', 'DISABLED') not null,
col6 int not null, to_be_deleted int)  ENGINE=ndbcluster;
show table status;
Name	Engine	Version	Row_format	Rows	Avg_row_length	Data_length	Max_data_length	Index_length	Data_free	Auto_increment	Create_time	Update_time	Check_time	Collation	Checksum	Create_options	Comment
t1	ndbcluster	9	Dynamic	100	0	0	NULL	0	0	1	NULL	NULL	NULL	latin1_swedish_ci	NULL		
t1	ndbcluster	9	Dynamic	0	0	0	NULL	0	0	1	NULL	NULL	NULL	latin1_swedish_ci	NULL		
insert into t1 values
(0,4,3,5,"PENDING",1,7),(NULL,4,3,5,"PENDING",1,7),(31,4,3,5,"PENDING",1,7), (7,4,3,5,"PENDING",1,7), (NULL,4,3,5,"PENDING",1,7), (100,4,3,5,"PENDING",1,7), (99,4,3,5,"PENDING",1,7), (8,4,3,5,"PENDING",1,7), (NULL,4,3,5,"PENDING",1,7);
show table status;
Name	Engine	Version	Row_format	Rows	Avg_row_length	Data_length	Max_data_length	Index_length	Data_free	Auto_increment	Create_time	Update_time	Check_time	Collation	Checksum	Create_options	Comment
t1	ndbcluster	9	Dynamic	100	0	0	NULL	0	0	102	NULL	NULL	NULL	latin1_swedish_ci	NULL		
t1	ndbcluster	9	Dynamic	9	0	0	NULL	0	0	102	NULL	NULL	NULL	latin1_swedish_ci	NULL		
select * from t1 order by col1;
col1	col2	col3	col4	col5	col6	to_be_deleted
0	4	3	5	PENDING	1	7
@@ -43,7 +43,7 @@ change column col2 fourth varchar(30) not null after col3,
modify column col6 int not null first;
show table status;
Name	Engine	Version	Row_format	Rows	Avg_row_length	Data_length	Max_data_length	Index_length	Data_free	Auto_increment	Create_time	Update_time	Check_time	Collation	Checksum	Create_options	Comment
t1	ndbcluster	9	Dynamic	100	0	0	NULL	0	0	102	NULL	NULL	NULL	latin1_swedish_ci	NULL		
t1	ndbcluster	9	Dynamic	9	0	0	NULL	0	0	102	NULL	NULL	NULL	latin1_swedish_ci	NULL		
select * from t1 order by col1;
col6	col1	col3	fourth	col4	col4_5	col5	col7	col8
1	0	3	4	5		PENDING		0000-00-00 00:00:00
@@ -58,7 +58,7 @@ col6 col1 col3 fourth col4 col4_5 col5 col7 col8
insert into t1 values (2, NULL,4,3,5,99,"PENDING","EXTRA",'2004-01-01 00:00:00');
show table status;
Name	Engine	Version	Row_format	Rows	Avg_row_length	Data_length	Max_data_length	Index_length	Data_free	Auto_increment	Create_time	Update_time	Check_time	Collation	Checksum	Create_options	Comment
t1	ndbcluster	9	Dynamic	100	0	0	NULL	0	0	103	NULL	NULL	NULL	latin1_swedish_ci	NULL		
t1	ndbcluster	9	Dynamic	10	0	0	NULL	0	0	103	NULL	NULL	NULL	latin1_swedish_ci	NULL		
select * from t1 order by col1;
col6	col1	col3	fourth	col4	col4_5	col5	col7	col8
1	0	3	4	5		PENDING		0000-00-00 00:00:00
+2 −2
Original line number Diff line number Diff line
@@ -150,7 +150,7 @@ insert into t1 values(9,'b9',999,'dd9');
commit;
explain select * from t1;
id	select_type	table	type	possible_keys	key	key_len	ref	rows	Extra
1	SIMPLE	t1	ALL	NULL	NULL	NULL	NULL	100	
1	SIMPLE	t1	ALL	NULL	NULL	NULL	NULL	9	
select * from t1 order by a;
a	b	c	d
1	b1	111	dd1
@@ -185,7 +185,7 @@ insert into t1 values(2,@b2,222,@d2);
commit;
explain select * from t1;
id	select_type	table	type	possible_keys	key	key_len	ref	rows	Extra
1	SIMPLE	t1	ALL	NULL	NULL	NULL	NULL	100	
1	SIMPLE	t1	ALL	NULL	NULL	NULL	NULL	2	
select a,length(b),substr(b,1+2*900,2),length(d),substr(d,1+3*900,3)
from t1 order by a;
a	length(b)	substr(b,1+2*900,2)	length(d)	substr(d,1+3*900,3)
+14 −0
Original line number Diff line number Diff line
@@ -421,11 +421,25 @@ INSERT INTO t1 VALUES
(6,6,6),(7,7,7),(8,8,8),(9,9,9),(10,10,10);
ERROR 23000: Duplicate entry '10' for key 1
begin;
SELECT COUNT(*) FROM t1;
COUNT(*)
2000
INSERT INTO t1 VALUES 
(2001,2001,2001),(2002,2002,2002),(2003,2003,2003),(2004,2004,2004),(2005,2005,2005);
SELECT COUNT(*) FROM t1;
COUNT(*)
2005
INSERT INTO t1 VALUES 
(1,1,1),(2,2,2),(3,3,3),(4,4,4),(5,5,5),
(6,6,6),(7,7,7),(8,8,8),(9,9,9),(10,10,10);
ERROR 23000: Duplicate entry '10' for key 1
SELECT COUNT(*) FROM t1;
COUNT(*)
2000
commit;
SELECT COUNT(*) FROM t1;
COUNT(*)
2000
insert into t1 select * from t1 where b < 10 order by pk1;
ERROR 23000: Duplicate entry '9' for key 1
DROP TABLE t1;
+7 −0
Original line number Diff line number Diff line
@@ -35,3 +35,10 @@ select length(a) from t1;
select length(uncompress(a)) from t1;
drop table t1;


#
# Bug #5497: a problem with large strings
#

set @@max_allowed_packet=1048576*100;
select length(compress(repeat('aaaaaaaaaa', 10000000)));
Loading