Laravel MySQL PHP

Mysql General Error 1364 Field Doesn’t Have Default Value

Hi All,

Since I’ve updated my homestead to 0.3.0 and mysql version is upgrade to 5.7.4. From that moment, my old projects has been started to throw problems which is Mysql General Error 1364 Field doesn’t have default value.

Even migrations was not working, there has to be a problem. After my first research I’ve found a solution for Php Laravel Projects there is a “strict” parameter for mysql connection, when I set it true migrations worked well.. But, in some cases, I let the mysql to set default value such as integer fields are sets to ‘0’ and varchar fields are empty strings etc.. I need to use default values as before..