Disable ONLY FULL GROUP BY error in phpmyadmin or in MySQL

Here I can provide you two type of solutions.
If you have root access then go with second option. but if dont have any root access you can fixed by PHPMYADMIN. ( which is not recomanded by me. Because when you restart MySQL you have to re execute the query. )

So, let’s start the article for how to disable ONLY FULL GROUP BY error in my phpmyadmin or in MySQL.

My MySQL version is “Server version: 5.7.27-0ubuntu0.18.04.1-log (Ubuntu)” and I used UBUNTU 18.04 as operating system.

Option 1

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

Option 2

first of all find location of “my.cnf” by your running operating system.

Choose as per OS
mint: sudo nano /etc/mysql/my.cnf
ubuntu 16 and up: /etc/mysql/my.cnf
ubuntu 14-16: /etc/mysql/mysql.conf.d/mysqld.cnf

sudo nano /etc/mysql/my.cnf

Now after open “my.cnf” add below line end of file.

 

[mysqld]  
sql_mode = "STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"

 

sudo service mysql restart

 

sudo service apache2 restart

I hope you like this article. Keep visiting my website for more upcoming articles. If you need any help with How to disable ONLY FULL GROUP BY error in phpmyadmin or in MySQL you can contact me. You can ask me questions in comments also. You can connect me on social media as well links are below in the footer section. Keep connected. Happy Coding.

Prashant Sutharhttps://prashantsuthar.com
My self Prashant Suthar, I had experience worked with NodeJS, Core PHP, WordPress, CodeIgniter, Shopify, Prestashop, Opencart and many frameworks. I had some basic knowledge about server setup and maintenance. I also worked with third parties APIs like Twillio audio,video, SMS API, FB messenger API and many more. I am working as team lead & sr. developer in Ahmedabad, GJ, IN.

Comments

Similar Articles