MySQL Forums
Forum List  »  Newbie

Web App crashes when using MySQL v8.0
Posted by: Amine Marref
Date: December 06, 2021 03:15AM


I use a web app which has been developed to work with MySQL v5.7 and it works fine when I have MySQL v5.7 installed in the system. When I switch to MySQL v8.0 I get the 500 internal error message in the app, and I could trace it to the incorrect use of the "GROUP BY" statement.

For example, this is an error message: "#1055 - Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'bla bla bla' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by".

What options do I have to make the app work with MySQL v8.0? My dream solution is to play with the settings of the server to allow this "GROUP BY" error go undetected. Removing the "only_full_group_by" flag from "sql mode" got rid of the error, but introduced another 500 internal error earlier in the execution flow.

Inspecting the code, I found quite a few "GROUP BY" statements which could potentially cause the same errors. Since I am no MySQL wizard, I prefer solutions that do not require me to rewrite the MySQL code to make it compatible with the new restrictions imposed by the new version.


Options: ReplyQuote

Written By
Web App crashes when using MySQL v8.0
December 06, 2021 03:15AM

Sorry, only registered users may post in this forum.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.