报错:
Expression #1 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column ‘information_schema.tables.DATA_LENGTH’ which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by
方法一:数据库指令,但是重启mysql,会失效
select @@global.sql_mode
set @@global.sql_mode
='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION';
方法二:修改配置文件,重启,永久有效