The easiest solution is to turn off sql_mode=only_full_group_by. You can ask your hosting provider how to do this, or if you have a dedicated server you can do it yourself through SSH using the command.
Make sure the solution you use works after the restart of the server. This usually means updating the value saved in the MySQL configuration file: /etc/mysql/my.cnf