Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure MySQL server allow disable 'sql_mode=only_full_group_by'

I have an application that runs on node.js and queries the database hosted on Azure MySQL server, I have encountered an error message during a query with group by

"...this is incompatible with sql_mode=only_full_group_by".

Subsequently, I have tried to change my SQL user privilege with

SET GLOBAL sql_mode=(SELECT REPLACE(@@sql_mode,'ONLY_FULL_GROUP_BY',''));

but got an error message:

Error Code: 1227. Access denied; you need (at least one of) the SUPER or SYSTEM_VARIABLES_ADMIN privilege(s) for this operation

like image 496
HGG-Dev Avatar asked Sep 08 '25 11:09

HGG-Dev


1 Answers

You can do this from the "server parameters" in azure portal. You can get the option of sql_mode there. Just change that and save it

https://learn.microsoft.com/en-us/azure/mysql/howto-server-parameters

like image 144
user13632948 Avatar answered Sep 11 '25 04:09

user13632948