#Example Problem:
Expression #9 of SELECT list is not in GROUP BY clause and contains nonaggregated column
'table.column' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by
#Solved With:
use your_db;
SET sql_mode = '' ;
#or
SET GLOBAL sql_mode=(SELECT REPLACE(@@sql_mode,'ONLY_FULL_GROUP_BY',''));
#or config mysql service
$ sudo vim /etc/mysql/conf.d/mysql.cnf
[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
$ save..
$ sudo service mysql restart || sudo service mysql-server restart
Created
March 6, 2018 08:36
-
-
Save r17x/734cab981731e8be705d6e1652c79110 to your computer and use it in GitHub Desktop.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment