Get the App
SLTechnology News&Howtos  ›  Servers  › 

How to solve the problem of "only_full_group_by" in MySQL error report

Shulou Source: shulou.com Published: 2022-06-01 11:13:03 10月03日 Update

This article mainly explains the "MySQL error" only_full_group_by "how to solve", the article explains the content is simple and clear, easy to learn and understand, now please follow the editor's train of thought slowly in depth, together to study and learn "MySQL error" only_full_group_by "how to solve" it!

Error message: SQLSTATE [42000]: Syntax error or access violation: 1055 Expression # 1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'atl.atl_order.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by.

Solution:

Comment out the only_full_group_by option in the configuration file. Add the following configuration: sql_mode = STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION.

Thank you for your reading, the above is the content of "MySQL error" only_full_group_by "how to solve", after the study of this article, I believe you have a deeper understanding of how to solve this problem of MySQL error "only_full_group_by". The specific use of the situation also needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

Tags: Learning content configuration methods that is ideas situations documents articles more comments knowledge knowledge points articles follow questions practice push prompt research Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno macOS MySQL Xiaomi Apple Docker