Skip to Content Skip to Menu

Privacy plugin causing user search to fail?

  • dpk
  • dpk
  • OFFLINE
  • Posts: 25
  • Thanks: 0
  • Karma: 3
15 years 4 months ago #103353 by dpk
System:
Joomla 1.5.11
CB 1.2.1
mySQL 4.1

Problem:
Searches made with CB user search typically fail if CB Privacy 1.0 RC is active and applied to CB fields.

Errors:
[code:1]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 '))' at line 8 SQL=SELECT COUNT(*) FROM jos_comprofiler ue, jos_users u WHERE u.block = 0 AND ue.approved = 1 AND ue.confirmed = 1 AND ue.banned = 0 AND u.gid IN ( 18, 31, 19, 20, 21, 30, 23, 24, 25) AND u.`id` = ue.`id` AND (())[/code:1]

In the following example, the cb_neighborhood field had user-defined privacy settings enabled, but no users had set the field to private, and most users had no data in their cb_neighborhood field. Same result when the tab (but not the field) containing cb_neighborhoods allowed user-defined privacy settings:

[code:1]500 - JDatabaseMySQL::query: 1052 - Column 'id' in on clause is ambiguous SQL=SELECT COUNT(*) FROM jos_comprofiler ue, jos_users u LEFT JOIN `jos_comprofiler_privacy` AS ja ON ((ja.`userid` = `id`) AND (ja.`xid` = 126) AND (ja.`type` = 'field')) WHERE u.block = 0 AND ue.approved = 1 AND ue.confirmed = 1 AND ue.banned = 0 AND u.gid IN ( 18, 31, 19, 20, 21, 30, 23, 24, 25) AND u.`id` = ue.`id` AND ((ue.`cb_neighborhood` LIKE '%The Bronx%') AND (ISNULL( ja.rule )))[/code:1]

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

Moderators: beatnantkrileon
Powered by Kunena Forum