diff options
author | msvensson@pilot.blaudden <> | 2007-05-19 18:15:08 +0200 |
---|---|---|
committer | msvensson@pilot.blaudden <> | 2007-05-19 18:15:08 +0200 |
commit | bc69d072f3c3d5af79a0835d92ac242c3cef2ba0 (patch) | |
tree | 866205fb4f1699d623d7ee1fc8b5da8fb5ad342b /mysql-test/t/mysql_upgrade.test | |
parent | c3f407a07a0ed22744e23b9b2c94b5ee8894ba2d (diff) | |
download | mariadb-git-bc69d072f3c3d5af79a0835d92ac242c3cef2ba0.tar.gz |
Bug #28401 mysql_upgrade Failed with STRICT_ALL_TABLES, ANSI_QUOTES and NO_ZERO_DATE
- The SQL commands used by mysql_upgrade are written to be run
with sql_mode set to '' - thus the scripts should change sql_mode
for the session to make sure the SQL is legal.
Diffstat (limited to 'mysql-test/t/mysql_upgrade.test')
-rw-r--r-- | mysql-test/t/mysql_upgrade.test | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/mysql-test/t/mysql_upgrade.test b/mysql-test/t/mysql_upgrade.test index 3f9626fcc42..233e8c7c256 100644 --- a/mysql-test/t/mysql_upgrade.test +++ b/mysql-test/t/mysql_upgrade.test @@ -55,3 +55,16 @@ DROP USER mysqltest1@'%'; --replace_regex /.*mysqlcheck.*: Got/mysqlcheck: Got/ /\([0-9]*\)/(errno)/ --error 1 --exec $MYSQL_UPGRADE --skip-verbose --force --host=not_existing_host 2>&1 + +# +# Bug #28401 mysql_upgrade Failed with STRICT_ALL_TABLES, ANSI_QUOTES and NO_ZERO_DATE +# + +# The SQL commands used by mysql_upgrade are written to be run +# with sql_mode set to '' - thus the scripts should change sql_mode +# for the session to make sure the SQL is legal. + +# Test by setting sql_mode before running mysql_upgrade +set GLOBAL sql_mode='STRICT_ALL_TABLES,ANSI_QUOTES,NO_ZERO_DATE'; +--exec $MYSQL_UPGRADE --skip-verbose --force 2>&1 +eval set GLOBAL sql_mode=default; |