summaryrefslogtreecommitdiff
path: root/mysql-test/t/log_tables.test
diff options
context:
space:
mode:
authorunknown <antony@pcg5ppc.xiphis.org>2007-10-18 14:48:04 -0700
committerunknown <antony@pcg5ppc.xiphis.org>2007-10-18 14:48:04 -0700
commit57600b02d0faaa6d3346a66beb6d3cedb273bae3 (patch)
tree5fe9a13eb429d1a6ce589363a5186339f72b8403 /mysql-test/t/log_tables.test
parent03bef972d3b508013cfcad2de294569ecdf16158 (diff)
downloadmariadb-git-57600b02d0faaa6d3346a66beb6d3cedb273bae3.tar.gz
Bug#31473
"CSV does not work with NULL value in datetime fields" Attempting to insert a row with a NULL value for a DATETIME field results in a CSV file which the storage engine cannot read. Don't blindly assume that "0" is acceptable for all field types, Since CSV does not support NULL, we find out from the field the default non-null value. Do not permit the creation of a table with a nullable columns. mysql-test/r/csv.result: test for bug 31473 mysql-test/r/log_tables.result: change in results due to bugfix 31473 mysql-test/r/system_mysql_db.result: change in results due to bugfix 31473 mysql-test/t/csv.test: test for bug 31473 mysql-test/t/log_tables.test: due to bug31473, all columns in CSV tables must be declared as NOT NULL scripts/mysql_system_tables.sql: due to bug31473, all columns in CSV tables must be declared as NOT NULL storage/csv/ha_tina.cc: bug31473 Don't blindly assume that "0" is acceptable for all field types, Since CSV does not support NULL, we find out from the field the default non-null value. Do not permit the creation of a table with a nullable columns;
Diffstat (limited to 'mysql-test/t/log_tables.test')
-rw-r--r--mysql-test/t/log_tables.test18
1 files changed, 9 insertions, 9 deletions
diff --git a/mysql-test/t/log_tables.test b/mysql-test/t/log_tables.test
index 89c7c255554..06011b85495 100644
--- a/mysql-test/t/log_tables.test
+++ b/mysql-test/t/log_tables.test
@@ -253,11 +253,11 @@ use mysql;
CREATE TABLE `general_log` (
`event_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP
ON UPDATE CURRENT_TIMESTAMP,
- `user_host` mediumtext,
- `thread_id` int(11) DEFAULT NULL,
- `server_id` int(11) DEFAULT NULL,
- `command_type` varchar(64) DEFAULT NULL,
- `argument` mediumtext
+ `user_host` mediumtext NOT NULL,
+ `thread_id` int(11) NOT NULL,
+ `server_id` int(11) NOT NULL,
+ `command_type` varchar(64) NOT NULL,
+ `argument` mediumtext NOT NULL
) ENGINE=CSV DEFAULT CHARSET=utf8 COMMENT='General log';
CREATE TABLE `slow_log` (
@@ -268,10 +268,10 @@ CREATE TABLE `slow_log` (
`lock_time` time NOT NULL,
`rows_sent` int(11) NOT NULL,
`rows_examined` int(11) NOT NULL,
- `db` varchar(512) DEFAULT NULL,
- `last_insert_id` int(11) DEFAULT NULL,
- `insert_id` int(11) DEFAULT NULL,
- `server_id` int(11) DEFAULT NULL,
+ `db` varchar(512) NOT NULL,
+ `last_insert_id` int(11) NOT NULL,
+ `insert_id` int(11) NOT NULL,
+ `server_id` int(11) NOT NULL,
`sql_text` mediumtext NOT NULL
) ENGINE=CSV DEFAULT CHARSET=utf8 COMMENT='Slow log';