After we recently updated to MySQL 5.6.27 (from the Ubuntu repo), this option now works. So this appears to have been a problem with the previ
Woks fine for me on ubuntu 16.04. path: /etc/mysql/mysql.cnf
and paste that
[mysqld]
#
# * Basic Settings
#
sql_mode = "NO_ENGINE_SUBSTITUTION"
It should be:
[mysqld]
sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
instead of
[mysqld]
sql_mode="NO_ENGINE_SUBSTITUTION"
then restart mysqld service.
For me it was a permission problem.
enter:
mysqld --verbose --help | grep -A 1 "Default options"
[Warning] World-writable config file '/etc/mysql/my.cnf' is ignored.
So try to execute the following, and then restart the server
chmod 644 '/etc/mysql/my.cnf'
It will give mysql access to read and write to the file.
[Fixed] Server version: 10.1.38-MariaDB - mariadb.org binary distribution
Go to: C:\xampp\mysql\bin open my.ini in notepad and find [mysqld] (line number 27) then after this line(line no 28) just type: skip-grant-tables
save the file and then reload the phpmyadmin page.It worked for me.
For me both keys for sql-mode
worked. Whether I used
# dash no quotes
sql-mode=NO_ENGINE_SUBSTITUTION
or
# underscore no quotes
sql_mode=NO_ENGINE_SUBSTITUTION
in the my.ini
file made no difference and both were accepted, as far as I could test it.
What actually made a difference was a missing newline at the end of the my.ini
file.
So everyone having problems with this or similar problems with my.ini
/my.cnf
: Make sure there is a blank line at the end of the file!
Tested using MySQL 5.7.27.
My problem was that I had spaces in between the options on 5.7.20. Removing them so the line looked like
[mysqld]
sql-mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION