Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Add `columns_for_distinct` for MySQL 5.7 with ONLY_FULL_GROUP_BY #22241
In MySQL 5.7.5 and up, ONLY_FULL_GROUP_BY affects handling of queries
The default SQL mode in MySQL 5.7 includes these modes:
And in MySQL 5.7.5 and up,
This means that Rails doesn't work on MySQL 5.7 with default sql_mode. We need to fix this issue and should backport to 4-2-stable.
diff --git a/activerecord/test/config.example.yml b/activerecord/test/config.example.yml index 58e2d45..8168b29 100644 --- a/activerecord/test/config.example.yml +++ b/activerecord/test/config.example.yml @@ -53,6 +53,7 @@ connections: mysql2: arunit: + strict: :default username: rails encoding: utf8 collation: utf8_unicode_ci