Skip to content

Commit ba570a1

Browse files
MySQL sql_mode change (#239)
* MySQL sql_mode change * Fixed formatting
1 parent e7588b7 commit ba570a1

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

source/upgrading/upgrade/upgrade_notes.rst

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,3 +101,23 @@ added in CloudStack's db.properties file:
101101
db.cloud.driver=jdbc:mysql
102102

103103
db.usage.driver=jdbc:mysql
104+
105+
106+
MySQL 8.0 sql mode change
107+
-------------------------
108+
109+
MySQL mode (sql_mode) has changed in CloudStack db.properties to
110+
"STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,
111+
ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION".
112+
113+
This gets automatically applies to the MySQL session used by CloudStack management server.
114+
115+
If the admin uses MySQL directly and wants to query tables it is advised to change the sql_mode in the corresponding session or globally.
116+
117+
Eg. mysql> set global sql_mode="STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,
118+
"> ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION";
119+
Query OK, 0 rows affected (0.00 sec)
120+
121+
mysql> set sql_mode="STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,
122+
"> ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION";
123+
Query OK, 0 rows affected (0.00 sec)

0 commit comments

Comments
 (0)