I took a project that a few years ago and noted that CURRENT_TIMESTAMP is sent with a lot of php calls to update the datetime field in a lot of rows. This works great in a live environment, however, this is not the case on my local installation.
Both Live DB and my local version of the WAMP64 download work on MySQL5.7.19.
The PHP script executing the request, which includes the insert CURRENT_TIMESTAMP, will return with the following error:
Invalid default value for 'last_update' timestamp
Again, on a real server, this works without problems. Both use MySQLi to execute these insert queries.
Is there something I am missing here? Is there some server-side configuration parameter that allows CURRENT_TIME to be inserted into the timestamp field?
source share