How to resolve “ORDER BY clause is not in SELECT list” caused MySQL 5.7 with SELECT DISTINCT and ORDER BY

前端 未结 8 815
故里飘歌
故里飘歌 2020-12-29 20:21

I installed the new Ubuntu and my code has got a problem with MySQL.

( ! ) Warning: PDOStatement::execute(): SQLSTAT         


        
8条回答
  •  生来不讨喜
    2020-12-29 20:37

    If you have phpMyAdmin:

    1-go to the Variables tabs

    2-search label "sql mode"

    3-edit the content and delete the mode : "ONLY_FULL_GROUP_BY"

    4-save

    NB: don't forget to verify the comma separator

提交回复
热议问题