Mysql Maria DB fields don't have defualt value

Hi,

Have a look at Webmin / Servers ⇾ MySQL Database Server: Edit Config Files page and edit /etc/mysql/mysql.conf.d/mysqld.cnf file.

As the default for MySQL on Ubuntu 20.04 includes STRICT_TRANS_TABLES for sql_mode:

… all you should do is to copy defaults and removing wished option, and adding that line of directives to mysqld.cnf file, under [mysqld] section and restarting MySQL aftetwards:

sql_mode=ONLY_FULL_GROUP_BY,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION

This will preserve defaults minus mentioned option you wished to remove, and that will survive restarts/reboots.

1 Like