MySQL #1140 - Mixing of GROUP columns

前端 未结 7 1226
难免孤独
难免孤独 2020-11-29 11:27

Hi wondering if perhaps someone could shed some light on the below error. The sql works fine locally but i get the the below error remotely.

SQL query:

<         


        
7条回答
  •  广开言路
    2020-11-29 11:46

    when you use aggregate functions in sql like sum(),min(),max() you must be use group by

    But in latest sql u have to use all the columns in select as a group By too.

    for this in laravel project you use in config->database

    'strict' => false,

    and clear config cache by running php artisan config:cache.

    i think it will be more helpfull for you.

提交回复
热议问题