DB query error related to FLEXIaccess

More
13 years 2 months ago #20273 by scorpion_pt
Related with this issue we are receiving this error, activating debug:
Code:
500 - JDatabaseMySQL::query: 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') ) ORDER BY ordering ASC' at line 1 SQL=SELECT c.*, CASE WHEN CHAR_LENGTH( c.alias ) THEN CONCAT_WS( ':', c.id, c.alias ) ELSE c.id END AS slug FROM jos_categories AS c WHERE c.published = 1 AND c.parent_id = 64 AND ( c.access <= 2 OR c.id IN () ) ORDER BY ordering ASC Call stack # Function Location 1 JSite->dispatch() /var/www/rr_cabelosonline/index.php:68 2 JComponentHelper->renderComponent() /var/www/rr_cabelosonline/includes/application.php:124 3 require_once() /var/www/rr_cabelosonline/libraries/joomla/application/component/helper.php:162 4 JController->execute() /var/www/rr_cabelosonline/components/com_flexicontent/flexicontent.php:71 5 FlexicontentController->display() /var/www/rr_cabelosonline/libraries/joomla/application/component/controller.php:236 6 JController->display() /var/www/rr_cabelosonline/components/com_flexicontent/controller.php:50 7 FlexicontentViewCategory->display() /var/www/rr_cabelosonline/libraries/joomla/application/component/controller.php:310 8 JView->get() /var/www/rr_cabelosonline/components/com_flexicontent/views/category/view.html.php:75 9 FlexicontentModelCategory->getChilds() /var/www/rr_cabelosonline/libraries/joomla/application/component/view.php:364 10 JModel->_getList() /var/www/rr_cabelosonline/components/com_flexicontent/models/category.php:719 11 JFDatabase->loadObjectList() /var/www/rr_cabelosonline/libraries/joomla/application/component/model.php:284 12 JDatabaseMySQLi->loadObjectList() /var/www/rr_cabelosonline/plugins/system/jfdatabase/jfdatabase_inherit.php:334 13 JFDatabase->query() /var/www/rr_cabelosonline/libraries/joomla/database/database/mysqli.php:474 14 JDatabaseMySQLi->query() /var/www/rr_cabelosonline/plugins/system/jfdatabase/jfdatabase_inherit.php:656 15 JError->raiseError() /var/www/rr_cabelosonline/libraries/joomla/database/database/mysqli.php:247 16 JError->raise() /var/www/rr_cabelosonline/libraries/joomla/error/error.php:171 17 JException->__construct() /var/www/rr_cabelosonline/libraries/joomla/error/error.php:136

We can find the above code here:
/components/com_flexicontent/models/category.php
Line #580

Any suggestion?

Tx in advance ;)

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #20274 by scorpion_pt
This is a Flexiaccess related issue.

If the user isn't associated with a flexiaccess group all working ok.
The problem arises when we assign the user to an flexiaccess collective group. Then - at the frontend and making login - we receive the above error.

Tx

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #20280 by ggppdk
mmm, how could this bug have escaped so long? This bug breaks category item list if you disable the show authorized links and in FLEXIaccess you have not set any permissions for the category and/or the items ...

In file components/com_flexicontent/models/category.php
replace lines:
Code:
if (isset($readperms['item'])) { ... if (isset($readperms['category'])) { ... if (isset($readperms['field'])) {
respectively with:
Code:
if ( isset($readperms['item']) && count($readperms['item']) ) { ... if (isset($readperms['category']) && count($readperms['category']) ) { ... if (isset($readperms['field']) && count($readperms['field']) ) {

Also the bug POSTed in this topic
www.flexicontent.org/forum/index ... pic#p20265
existed already
and just appeared because of this bug


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 1.124 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline