Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2017-08-26 16:56:17

Plugin Author
From: Germany/Ukraine
Registered: 2007-10-08
Posts: 270

MariaDB >= 10.2.4 "strict mode" and Textpattern 4.6.2

After upgrading MariaDB to 10.2.8 I ran into some errors caused by the now default “strict mode”. They changed the default behavior for invalid values:

A mode where at least one of STRICT_TRANS_TABLES or STRICT_ALL_TABLES is enabled is called strict mode. With strict mode not set (default in version <= MariaDB 10.2.3), MariaDB will automatically adjust invalid values, for example, truncating strings that are too long, or adjusting numeric values that are out of range, and produce a warning.

With strict mode set (default from MariaDB 10.2.4), the statements will fail, and an error will be returned instead. The IGNORE keyword can be used when strict mode is set to convert the error to a warning.

So for example MariaDB was complaining about no default value for ‘custom_x’ fields or more than 255 characters in ‘description’ field.

Switching back the default behavior with something like SET GLOBAL sql_mode = ''; helped so far, but not everybody is able to administrate his database software.


Board footer

Powered by FluxBB