summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--inc/database.inc.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/inc/database.inc.php b/inc/database.inc.php
index 48d8e3c6..654b6e92 100644
--- a/inc/database.inc.php
+++ b/inc/database.inc.php
@@ -37,7 +37,8 @@ class Database
Util::traceError('Connecting to the local database failed: ' . $e->getMessage());
}
if (CONFIG_DEBUG) {
- Database::exec("SET sql_mode='STRICT_TRANS_TABLES'");
+ Database::exec("SET SESSION sql_mode='STRICT_ALL_TABLES,NO_ENGINE_SUBSTITUTION,ERROR_FOR_DIVISION_BY_ZERO'");
+ Database::exec("SET SESSION innodb_strict_mode=ON");
register_shutdown_function(function() {
self::examineLoggedQueries();
});