Remove file before writing to it.
This commit is contained in:
parent
5e4b4ca6ab
commit
a5eab2c65f
@ -1424,6 +1424,7 @@ DROP TABLE test_repair_table2;
|
|||||||
|
|
||||||
# Corrupt csv file and see if we can repair it
|
# Corrupt csv file and see if we can repair it
|
||||||
CREATE TABLE test_repair_table3 ( val integer ) ENGINE = CSV;
|
CREATE TABLE test_repair_table3 ( val integer ) ENGINE = CSV;
|
||||||
|
--remove_file $MYSQLTEST_VARDIR/master-data/test/test_repair_table3.CSV
|
||||||
--write_file $MYSQLTEST_VARDIR/master-data/test/test_repair_table3.CSV
|
--write_file $MYSQLTEST_VARDIR/master-data/test/test_repair_table3.CSV
|
||||||
"1"
|
"1"
|
||||||
"4"
|
"4"
|
||||||
@ -1476,6 +1477,7 @@ CREATE TABLE test_repair_table5 (
|
|||||||
) ENGINE = CSV;
|
) ENGINE = CSV;
|
||||||
|
|
||||||
# Corrupt a table -- put a file with wrong # of columns
|
# Corrupt a table -- put a file with wrong # of columns
|
||||||
|
--remove_file $MYSQLTEST_VARDIR/master-data/test/test_repair_table5.CSV
|
||||||
--write_file $MYSQLTEST_VARDIR/master-data/test/test_repair_table5.CSV
|
--write_file $MYSQLTEST_VARDIR/master-data/test/test_repair_table5.CSV
|
||||||
"1","101","IBM"
|
"1","101","IBM"
|
||||||
EOF
|
EOF
|
||||||
@ -1629,6 +1631,7 @@ insert into bug22080_1 values(2,'string');
|
|||||||
insert into bug22080_1 values(3,'string');
|
insert into bug22080_1 values(3,'string');
|
||||||
|
|
||||||
# Create first corrupt file as described in bug report
|
# Create first corrupt file as described in bug report
|
||||||
|
--remove_file $MYSQLTEST_VARDIR/master-data/test/bug22080_2.CSV
|
||||||
--write_file $MYSQLTEST_VARDIR/master-data/test/bug22080_2.CSV
|
--write_file $MYSQLTEST_VARDIR/master-data/test/bug22080_2.CSV
|
||||||
1,"string"
|
1,"string"
|
||||||
2","string"
|
2","string"
|
||||||
@ -1636,6 +1639,7 @@ insert into bug22080_1 values(3,'string');
|
|||||||
EOF
|
EOF
|
||||||
|
|
||||||
# Create second corrupt file as described in bug report
|
# Create second corrupt file as described in bug report
|
||||||
|
--remove_file $MYSQLTEST_VARDIR/master-data/test/bug22080_3.CSV
|
||||||
--write_file $MYSQLTEST_VARDIR/master-data/test/bug22080_3.CSV
|
--write_file $MYSQLTEST_VARDIR/master-data/test/bug22080_3.CSV
|
||||||
1,"string"
|
1,"string"
|
||||||
"2",string"
|
"2",string"
|
||||||
@ -1696,6 +1700,7 @@ check table t1;
|
|||||||
drop table t1;
|
drop table t1;
|
||||||
|
|
||||||
create table t1(a int, b int) engine=csv;
|
create table t1(a int, b int) engine=csv;
|
||||||
|
--remove_file $MYSQLTEST_VARDIR/master-data/test/t1.CSV
|
||||||
--write_file $MYSQLTEST_VARDIR/master-data/test/t1.CSV
|
--write_file $MYSQLTEST_VARDIR/master-data/test/t1.CSV
|
||||||
1, 1E-2
|
1, 1E-2
|
||||||
-2E2, .9
|
-2E2, .9
|
||||||
|
Loading…
x
Reference in New Issue
Block a user