MariaDB Error: 1364 Field ‘display_name’ doesn’t have default value

Spent too much time over the bank holiday weekend looking for a solution to this problem.
It had appeared after I had upgraded the code for my command and control cloud system.

Anyway, turns out that I had also updated MariaDB from 10.1.x to 10.2.x

So after many wasted hours this was fixed by a simple, make sure that the database was not in strict mode.

sql_mode=''

in my /etc/my.cnf configuration file.

I hope this saves you the time and effort debugging that I had made.

Author: Andrew

4 thoughts on “MariaDB Error: 1364 Field ‘display_name’ doesn’t have default value

  1. Thank you, I have to use this in 10.4 version.

    I had default sql_mode = NO_ENGINE_SUBSTITUTION, after update was STRICT_TRANS_TABLES,​ERROR_FOR_DIVISION_BY_ZERO,​NO_AUTO_CREATE_USER,​NO_ENGINE_SUBSTITUTION

    You can change this during working database:
    SELECT @@GLOBAL.sql_mode;
    SELECT @@SESSION.sql_mode;

    SET GLOBAL sql_mode = ‘NO_ENGINE_SUBSTITUTION’;
    SET SESSION sql_mode = ‘NO_ENGINE_SUBSTITUTION’;

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.