Report this

What is the reason for this report?

Remove only_full_group_by from sql mode

Posted on April 7, 2020

Hello. I’m trying to remove only_full_group_by from sql mode but in the MySQL droplet settings UI there is no only_full_group_by to remove.

Although when I connect to the DB from command line and I run command SELECT @@sql_mode;

which outputs

REAL_AS_FLOAT,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,ONLY_FULL_GROUP_BY,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION

Which HAS the only_full_group_by ! Any ideas?



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi @kwstasna3 @MariusJP,

I assume your question is about MySQL managed database; With MySQL managed database you ​should now be able to set the global SQL mode for MySQL Cluster.

You can set the SQL mode by finding the cluster on the Databases page -> click the cluster’s name -> Settings tab - > Global SQL mode -> Edit button -> from the drop-down menu select the SQL mode you want to modify

Save to persist the change or cancel to revert.

The link provides more information on how to set global SQL mode on MySQL clusters.

https://docs.digitalocean.com/products/databases/mysql/how-to/set-sql-mode/

Once you have edited the global SQL mode from the cloud control panel run the below command to check the current global SQL mode.

SELECT @@GLOBAL.sql_mode;

If you are executing SELECT @@sql_mode; this will only show session-level sql_mode which tends to change when you log out of MySQL managed database and log in back.

I hope this helps!

Regards, Rajkishore

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.