Page 1 of 2
Commands out of sync Error
Posted: 29 Jun 2022, 09:58
by ch2856
Hi,
J4.1.5 and Phoca 4.0.1
When I try to edit a product I get this error "Commands out of sync; you can't run this command now"
Thanks
Re: Commands out of sync Error
Posted: 30 Jun 2022, 18:24
by Jan
Hi, can you enable debug mode and paste here the full error message including call stack?
Jan
Re: Commands out of sync Error
Posted: 25 Jul 2022, 15:46
by drmenzelit
Hi Jan,
I'm experiencing the same issue, the error appears in frontend when one click on a product and also in backend when trying to edit a product
Code: Select all
2014 Commands out of sync; you can't run this command now
Call stack
# Function Location
1 () JROOT/libraries/vendor/joomla/database/src/Mysqli/MysqliStatement.php:525
2 Joomla\Database\Mysqli\MysqliStatement->fetch() JROOT/libraries/vendor/joomla/database/src/DatabaseDriver.php:760
3 Joomla\Database\DatabaseDriver->fetchObject() JROOT/libraries/vendor/joomla/database/src/DatabaseDriver.php:1378
4 Joomla\Database\DatabaseDriver->loadObjectList() JROOT/administrator/components/com_phocacart/libraries/phocacart/related/related.php:163
5 PhocacartRelated::getRelatedItemsById() JROOT/components/com_phocacart/views/item/view.html.php:131
6 PhocaCartViewItem->display() JROOT/libraries/src/MVC/Controller/BaseController.php:697
7 Joomla\CMS\MVC\Controller\BaseController->display() JROOT/components/com_phocacart/controller.php:53
8 PhocaCartController->display() JROOT/libraries/src/MVC/Controller/BaseController.php:735
9 Joomla\CMS\MVC\Controller\BaseController->execute() JROOT/components/com_phocacart/phocacart.php:16
10 require_once() JROOT/libraries/src/Dispatcher/LegacyComponentDispatcher.php:69
11 Joomla\CMS\Dispatcher\LegacyComponentDispatcher::Joomla\CMS\Dispatcher\{closure}() JROOT/libraries/src/Dispatcher/LegacyComponentDispatcher.php:71
12 Joomla\CMS\Dispatcher\LegacyComponentDispatcher->dispatch() JROOT/libraries/src/Component/ComponentHelper.php:389
13 Joomla\CMS\Component\ComponentHelper::renderComponent() JROOT/libraries/src/Application/SiteApplication.php:204
14 Joomla\CMS\Application\SiteApplication->dispatch() JROOT/libraries/src/Application/SiteApplication.php:243
15 Joomla\CMS\Application\SiteApplication->doExecute() JROOT/libraries/src/Application/CMSApplication.php:278
16 Joomla\CMS\Application\CMSApplication->execute() JROOT/includes/app.php:63
17 require_once() JROOT/index.php:32
Re: Commands out of sync Error
Posted: 25 Jul 2022, 17:53
by christine
Nice to see you here Viviana,
In the meantime, until Jan answers here.
Found something similar here, not the same, but maybe?
https://forum.joomla.org/viewtopic.php?f=831&p=3665741
PHP Version?
Kind regards
Christine
Re: Commands out of sync Error
Posted: 26 Jul 2022, 19:11
by drmenzelit
Code: Select all
Datenbanktyp mysql
Datenbankversion 5.7.38-log
Datenbankzeichensatz utf8_general_ci
Datenbankverbindungszeichensatz utf8mb4_general_ci
PHP-Version 7.4.30
Re: Commands out of sync Error
Posted: 27 Jul 2022, 13:18
by Jan
Hi, thank you for the info, this is a very unusual error. I don't get such problem on any of my test servers:
I will try to search further
Jan
Re: Commands out of sync Error
Posted: 27 Jul 2022, 13:27
by christine
Re: Commands out of sync Error
Posted: 27 Jul 2022, 13:33
by Jan
The only one info from mysql is:
https://dev.mysql.com/doc/refman/8.0/en ... -sync.html but the problem is that these methods are managed by Joomla database object so in fact this cannot be influenced from the component
Do you get the same result when you try to run the SQL query manually in phpMyAdmin:
Code: Select all
SELECT DISTINCT a.id as id, a.title as title, a.image as image, a.alias as alias, a.description, a.description_long, SUBSTRING_INDEX(GROUP_CONCAT(c.id ORDER BY c.parent_id), ',', 1) as catid, SUBSTRING_INDEX(GROUP_CONCAT(c.title ORDER BY c.parent_id), ',', 1) as cattitle, SUBSTRING_INDEX(GROUP_CONCAT(c.alias ORDER BY c.parent_id), ',', 1) as catalias, GROUP_CONCAT(c.title SEPARATOR " ") AS categories_title FROM jos_phocacart_products AS a LEFT JOIN jos_phocacart_product_related AS t ON a.id = t.product_b LEFT JOIN jos_phocacart_product_categories AS pc ON pc.product_id = a.id LEFT JOIN jos_phocacart_categories AS c ON c.id = pc.category_id WHERE t.product_a = 1 GROUP BY a.id, a.title, a.alias, a.image, a.description, a.description_long;
Change prefix "jos_" to your own.
Re: Commands out of sync Error
Posted: 27 Jul 2022, 13:35
by Jan
Hi Christine, thank you for the links, now I see there is "
Datenbanktyp mysql", maybe if this will be changed to
mysqli (mysql -> mysqli), it can help
EDIT: But I am testing it with mysql on my test server, even, there is everything OK
Re: Commands out of sync Error
Posted: 27 Jul 2022, 13:44
by christine
Jan wrote: ↑27 Jul 2022, 13:35
Hi Christine, thank you for the links, now I see there is "
Datenbanktyp mysql", maybe if this will be changed to
mysqli (mysql -> mysqli), it can help
No Jan
The screenshot from Viviana is correct, as Databank Typ = MySQL.
But in Configuration > Server you can see, if there is: MySQLi or MySQL (PDO)
Christine