I had a massive update from PHP5.6 to PHP7.1 and and server components. Plus Joomla to latest version. Please if something does not work report on forum.

nbs_212
Total posts: 94
03 Nov 2013 21:49

Hi Sergey,

My Site is already live since last of June 2013, and running well up until this error came up.

This is happened, when we were trying to filter a spesific keyword using search feature, and gave an error with no data result.

It is only happened if we use "bank central" or "bank central asia" keyword in the filter, using "bank" or other keyword working fine. And it is happened at a specific user ID.

the summary:

User ID = "abc" using keyword: - "bank central" resulting error - "bank central asia" resulting error - "bank" no problem - Other keyword no problem

Other user has no problem with that and can use any keyword.

What is the problem?, and how to fix it.

Last Modified: 10 Aug 2017


Sergey
Total posts: 13,645
05 Nov 2013 05:24

I do not know if I do not know what is the query. can you see all sql queries in debug log and place it here? I mean those that are with subquery.


nbs_212
Total posts: 94
05 Nov 2013 08:12

Sergey, this is the query shown in debug mode.

JDatabaseMySQLi::query: 1242 - Subquery returns more than 1 row SQL=SELECT r.*,(SELECT id FROM qr7no_js_res_subscriptions WHERE record_id = r.id AND user_id = 981) as subscribed,(SELECT id FROM qr7no_js_res_favorite WHERE record_id = r.id AND user_id = 981) as bookmarked,0 as new,1 AS searchresult FROM qr7no_js_res_record AS r WHERE r.section_id = 1 AND r.published = 1 AND r.hidden = 0 AND r.parent_id = 0 AND r.fieldsdata LIKE '%bank central%' ORDER BY r.ctime DESC LIMIT 0, 20

Call stack

Function Location

1 JSite->dispatch() JROOT\index.php:42

2 JComponentHelper::renderComponent() JROOT\includes\application.php:197

3 JComponentHelper::executeComponent() JROOT\libraries\joomla\application\component\helper.php:351

4 require_once() JROOT\libraries\joomla\application\component\helper.php:383

5 JController->execute() JROOT\components\com_cobalt\cobalt.php:54

6 CobaltController->display() JROOT\libraries\joomla\application\component\controller.php:761

7 JController->display() JROOT\components\com_cobalt\controller.php:38

8 CobaltViewRecords->display() JROOT\libraries\joomla\application\component\controller.php:722

9 JView->get() JROOT\components\com_cobalt\views\records\view.html.php:132

10 CobaltModelRecords->getItems() JROOT\libraries\joomla\application\component\view.php:386

11 JModelList->getItems() JROOT\components\com_cobalt\models\records.php:244

12 JModel->_getList() JROOT\libraries\joomla\application\component\modellist.php:128

13 JDatabase->loadObjectList() JROOT\libraries\joomla\application\component\model.php:301

14 JDatabaseMySQLi->execute() JROOT\libraries\joomla\database\database.php:1100

15 JError::raiseError() JROOT\libraries\joomla\database\database\mysqli.php:396

16 JError::raise() JROOT\libraries\joomla\error\error.php:251


Sergey
Total posts: 13,645
05 Nov 2013 22:51

OK. Please run this queries and tell me if there is more than 1 in one of the records.

SELECT COUNT(id) AS number FROM qr7no_js_res_subscriptions WHERE user_id = 981 GROUP BY record_id ORDER BY number DESC;

SELECT COUNT(id) AS number FROM qr7no_js_res_favorite WHERE user_id = 981 GROUP BY record_id ORDER BY number DESC

Sergey
Total posts: 13,645
06 Nov 2013 00:45

When everything is ok. I made some fix. Should not display this error anymore.


Sergey
Total posts: 13,645
07 Nov 2013 22:39

Update to release yesterday.


nbs_212
Total posts: 94
08 Nov 2013 08:13

Sergey,

Which update should I use?, I have update Cobalt package and Emerald, but the error still came up.

JDatabaseMySQLi::query: 1242 - Subquery returns more than 1 row SQL=SELECT r.*,(SELECT id FROM qr7no_js_res_subscriptions WHERE record_id = r.id AND user_id = 981) as subscribed,(SELECT id FROM qr7no_js_res_favorite WHERE record_id = r.id AND user_id = 981) as bookmarked,0 as new,1 AS searchresult FROM qr7no_js_res_record AS r WHERE r.section_id = 1 AND r.published = 1 AND r.hidden = 0 AND r.parent_id = 0 AND r.fieldsdata LIKE '%bank central asia%' AND r.archive = 0 ORDER BY r.ctime DESC LIMIT 0, 20


Sergey
Total posts: 13,645
12 Nov 2013 01:29

I am sorry. Again I was thinking of Cobalt 8 and J3. I fixed that. Now I fixed Cobalt 7 and I'll update it within a few hours.


nbs_212
Total posts: 94
15 Nov 2013 01:25

Sergey,

It is working fine now.

Thank You


Guest
02 Aug 2017 21:17

Hi! I have this same problem, but in Cobalt 8. Can you please check that it's solved in the last version?

Thank you.


Sergey
Total posts: 13,645
10 Aug 2017 13:23

Sometimes it happens. It might be because of some MySQL internal errors.

You have to see debug console and find the query that return this error. Then you will see what to fix.

But for the next version of cobalt I've added new tool called Doctor. This one will check for those types of anomalies and fix those.

Replay Topic
Uploading
Click here to upload and insert file from you hard drive: (png, gif, jpg, jpeg, zip, txt, rar)
Powered by Cobalt