Commit cde34dfb authored by unknown's avatar unknown
Browse files

Little different behaviour in 5.0 and merge with new tests required these changes


mysql-test/r/archive.result:
  Changed order of tests so that the are before the unpredictable INSERT DELAYED
  Warning is produced during the rename
mysql-test/t/archive.test:
  Changed order of tests so that the are before the unpredictable INSERT DELAYED
  Warning is produced during the rename
parent 758f5d0a
Loading
Loading
Loading
Loading
+16 −14
Original line number Diff line number Diff line
@@ -184,6 +184,22 @@ fld1 fld3
250503	heaving
250504	population
250505	bomb
create table t3 engine=archive select * from t2;
select * from t3 where fld3='bonfire';
auto	fld1	companynr	fld3	fld4	fld5	fld6
1191	068504	00	bonfire	corresponds	positively	
select count(*) from t3;
count(*)
1199
rename table t3 to t4;
Warnings:
Error	7	Error on rename of './test/t3.ARN' to './test/t4.ARN' (Errcode: 2)
select * from t4 where fld3='bonfire';
auto	fld1	companynr	fld3	fld4	fld5	fld6
1191	068504	00	bonfire	corresponds	positively	
select count(*) from t4;
count(*)
1199
INSERT INTO t2 VALUES (1,000001,00,'Omaha','teethe','neat','');
INSERT INTO t2 VALUES (2,011401,37,'breaking','dreaded','Steinberg','W');
INSERT INTO t2 VALUES (3,011402,37,'Romans','scholastics','jarring','');
@@ -5020,18 +5036,4 @@ auto fld1 companynr fld3 fld4 fld5 fld6
3	011402	37	Romans	scholastics	jarring	
4	011403	37	intercepted	audiology	tinily	
INSERT DELAYED INTO t2 VALUES (4,011403,37,'intercepted','audiology','tinily','');
create table t3 engine=archive select * from t2;
select * from t3 where fld3='bonfire';
auto	fld1	companynr	fld3	fld4	fld5	fld6
1191	068504	00	bonfire	corresponds	positively	
select count(*) from t3;
count(*)
1203
rename table t3 to t4;
select * from t4 where fld3='bonfire';
auto	fld1	companynr	fld3	fld4	fld5	fld6
1191	068504	00	bonfire	corresponds	positively	
select count(*) from t4;
count(*)
1203
drop table t1, t2, t4;
+13 −11
Original line number Diff line number Diff line
@@ -1289,6 +1289,18 @@ select fld3 from t2 where (fld3 like "C%" and fld3 = "Chantilly");
select fld1,fld3 from t2 where fld1 like "25050%";
select fld1,fld3 from t2 where fld1 like "25050_";


#
# Test rename of table
#
create table t3 engine=archive select * from t2;
select * from t3 where fld3='bonfire';
select count(*) from t3;
rename table t3 to t4;
select * from t4 where fld3='bonfire';
select count(*) from t4;


#
# Test for insert after select
#
@@ -1308,19 +1320,9 @@ INSERT INTO t2 VALUES (1,000001,00,'Omaha','teethe','neat','') , (2,011401,37,'b
SELECT * FROM t2;

# Just test syntax, we will never know if the out put is right or wrong
# Must be the last test
INSERT DELAYED INTO t2 VALUES (4,011403,37,'intercepted','audiology','tinily','');
# 
# Cleanup, test is over
#

#
# Test rename of table
#
create table t3 engine=archive select * from t2;
select * from t3 where fld3='bonfire';
select count(*) from t3;
rename table t3 to t4;
select * from t4 where fld3='bonfire';
select count(*) from t4;

drop table t1, t2, t4;