AJAX error on product details

When I click on a product to open up its details I only get a text based version with errors “An error has occurred”. “If this error persists, please have your administrator disable Ajax for this module”

The suitecrm log shows

[i]Tue Oct 16 13:28:50 2018 [18895][1][FATAL] Mysqli_query failed.
Tue Oct 16 13:28:50 2018 [18895][1][FATAL] Error running count query for AOS_Products List: Query Failed: (
SELECT count() c FROM (
accounts.id AS account_id,
accounts.name AS billing_account,

				opportunity_id AS opportunity,
				billing_contact_id AS billing_contact,
				'' AS created_by_name,
				'' AS modified_by_name,
				'' AS assigned_user_name

			JOIN aos_products_quotes ON aos_products_quotes.product_id = aos_products.id AND aos_products.id = '2d506bfa-5b0f-d0f8-2074-5b663a786036' AND aos_products_quotes.deleted = 0 AND aos_products.deleted = 0
			JOIN aos_quotes ON aos_quotes.id = aos_products_quotes.parent_id AND aos_quotes.stage = 'Closed Accepted' AND aos_quotes.deleted = 0
			JOIN accounts ON accounts.id = aos_quotes.billing_account_id -- AND accounts.deleted = 0

			GROUP BY accounts.id
		) AS aos_quotes

	): MySQL error 1055: Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'abcd.aos_quotes.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by

Tue Oct 16 13:28:50 2018 [18895][1][FATAL] Exception handling in /var/www/yourcompany.com/html/suite/include/MVC/Controller/SugarController.php:400
Tue Oct 16 13:28:50 2018 [18895][1][FATAL] Exception in Controller: Database failure. Please refer to suitecrm.log for details.
Tue Oct 16 13:28:50 2018 [18895][1][FATAL] backtrace:
#0 /var/www/yourcompany.com/html/suite/include/database/DBManager.php(353): sugar_die(‘Database failur…’)
#1 /var/www/yourcompany.com/html/suite/include/database/DBManager.php(328): DBManager->registerError(‘Error running c…’, ‘Error running c…’, true)
#2 /var/www/yourcompany.com/html/suite/include/database/MysqliManager.php(179): DBManager->checkError(‘Error running c…’, true)
#3 /var/www/yourcompany.com/html/suite/data/SugarBean.php(1502): MysqliManager->query(’(\n \t\t\tSELECT co…’, true, ‘Error running c…’)
#4 /var/www/yourcompany.com/html/suite/data/SugarBean.php(1253): SugarBean->_get_num_rows_in_query(’(\n \t\t\tSELECT co…’, false)
#5 /var/www/yourcompany.com/html/suite/data/SugarBean.php(1016): SugarBean->process_union_list_query(Object(AOS_Products), ‘(\n \t\t\tSELECT * …’, 0, -1, 10, ‘’, Object(aSubPanel), ‘(\n \t\t\tSELECT co…’, Array)
#6 /var/www/yourcompany.com/html/suite/include/ListView/ListView.php(1132): SugarBean::get_union_related_list(Object(AOS_Products), ‘aos_quotes.id a…’, ‘asc’, ‘’, 0, -1, 10, ‘’, Object(aSubPanel))
#7 /var/www/yourcompany.com/html/suite/include/ListView/ListViewSubPanel.php(142): ListView->processUnionBeans(Object(AOS_Products), Object(aSubPanel), ‘aos_products_pu…’)
#8 /var/www/yourcompany.com/html/suite/include/SubPanel/SubPanel.php(220): ListViewSubPanel->process_dynamic_listview(‘AOS_Products’, Object(AOS_Products), Object(aSubPanel))
#9 /var/www/yourcompany.com/html/suite/include/SubPanel/SubPanelTiles.php(357): SubPanel->ProcessSubPanelListView(‘include/SubPane…’, Array)
#10 /var/www/yourcompany.com/html/suite/include/MVC/View/SugarView.php(1167): SubPanelTiles->display()
#11 /var/www/yourcompany.com/html/suite/include/MVC/View/SugarView.php(239): SugarView->_displaySubPanels()
#12 /var/www/yourcompany.com/html/suite/include/MVC/Controller/SugarController.php(435): SugarView->process()
#13 /var/www/yourcompany.com/html/suite/include/MVC/Controller/SugarController.php(375): SugarController->processView()
#14 /var/www/yourcompany.com/html/suite/include/MVC/SugarApplication.php(113): SugarController->execute()
#15 /var/www/yourcompany.com/html/suite/index.php(52): SugarApplication->execute()
#16 {main}[/i]

I have tried quick repair and rebuilding all of the java items.
There are no mods to the core code.
It was working fine for most of the day then suddenly this error.
Other modules seem to be displaying ok.
I am on 7.10.9 and php7.2.
Any ideas ? :huh:

See https://github.com/salesagility/SuiteCRM/issues/2869

You can try turning off this item of your “SQL_MODE” setting in MySQL:


But I am not sure of the consequences of this, please evaluate carefully.

1 Like

Thanks. That solved it.

I have the same issue.
Fresh install v7.11.0, PHP 7.1.25, MySQL 5.7.24, Debian 9
Imported old database (after upgrading to v7.11.0, but MySql was running 5.6.36 in Windows)
Sub-panels do not show (database error) unless I disable SQL_MODE ONLY_FULL_GROUP_BY.