When querying a GROUP BY statement com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException:Expression #2 of SELECT list is not in GROUP by Clause and contains nonaggregated column ' Col_user_6.a.start_time ' which is not functionally dependent on columns in Grou P BY clause; This is incompatible with sql_mode=only_full_group_by error
Workaround: Execute set GLOBAL sql_mode = '; Change the Sql_mode to non-only_full_group_by mode. Verify that the SELECT @ @GLOBAL is in effect. Sql_mode or select @ @sql_mode
SET Sql_mode = ' Strict_trans_tables,no_zero_in_date,no_zero_date,error_for_division_by_zero,no_auto_create_user, No_engine_substitution ';
Transferred from: http://www.cnblogs.com/grimm/p/5751911.html
Mysql> 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 '; MySQL> Set session sql_mode= ' Strict_trans_tables,no_zero_in_ Date,no_zero_date,error_for_division_by_zero,no_auto_create_user,no_engine_substitution ';
Transferred from: https://stackoverflow.com/questions/37619417/ Mysql5-7-upgrade-issue-group-by-incompatible-with-sql-mode-only-full-group-by
MySQL 5.7.9 Version sql_mode=only_full_group_by issue