By Eldad Caspi on Wednesday, 24 September 2014
Posted in Technical Issues
Likes 0
Views 1K
Votes 0
Hi there,

I have an urgent issue since updating to 1.3.5 earlier today.
When a user trying to register, he get the following message after the final step (2 steps):
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 'PRIVACY_ID`, `USER_ID`, `UID`, `TYPE`, `VALUE`) SELECT `D`.`ID` AS `PRIVACY_ID`,' AT LINE 1 SQL=INSERT INTO `SEJOC_SOCIAL_PRIVACY_ITEMS (`PRIVACY_ID`, `USER_ID`, `UID`, `TYPE`, `VALUE`) SELECT `D`.`ID` AS `PRIVACY_ID`, '1764' AS `USER_ID`, `A`.`ID` AS `UID`, `D`.`TYPE`, `D`.`VALUE` FROM `SEJOC_SOCIAL_FIELDS` AS `A` LEFT JOIN `SEJOC_SOCIAL_FIELDS_STEPS` AS `B` ON `B`.`ID` = `A`.`STEP_ID` LEFT JOIN `SEJOC_SOCIAL_APPS` AS `C` ON `C`.`ID` = `A`.`APP_ID` LEFT JOIN `SEJOC_SOCIAL_PRIVACY` AS `D` ON `D`.`RULE` = `C`.`ELEMENT` WHERE `D`.`TYPE` = 'FIELD' AND `B`.`TYPE` = 'PROFILES' AND `B`.`UID` = '1' AND `A`.`ID` NOT IN (SELECT `E`.`UID` FROM `SEJOC_SOCIAL_PRIVACY_ITEMS` AS `E` WHERE `E`.`TYPE` = 'FIELD' AND 


I have attached the access/ftp,
Please help(!)

Many thanks,
Eldad
Hello Dave,

I have put a fix in your site and now registration in your site is working as it should be. If you want to apply this fix at the other site, please simply copy this file: \administrator\components\com_easysocial\models\privacy.php and put it in the new site. Here I also attached to you this file so that others can use to fix this issue in their site.

Hello Eldad,

Regarding your issue, "unfortunately now i get "Invalid Token" page after the first or the second step in 4 out of 5 tries. Very unstable."
>> I am sorry but I unable to replicate this. Can you tell us the steps taken to reproduce this issue?

About this issue, "we got complains that users who have managed to register got a non valid activation code."
>> I have put a fix in your site. Can you ask your users to register again and see if this issue is still persist.

About this issue, "regarding the registration method, i'd set the "User Activation" method to be applied for the default profile type, but the admin keeps getting an email with "approve" or "reject" buttons, is this normal?"
>> I believe you have turn on this setting at the profile types: Send registration email to admin. http://screencast.com/t/BuYlou2ghUD .


Please be advise.
Thanks.
·
Wednesday, 24 September 2014 19:25
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Eldad,

I am sorry for the late reply.
I have put a fix on your site and now your site registration process is working correctly: http://screencast.com/t/THfic7lH43aJ . Can you verify this for me? Actually there is missing quote at the table name. How to fix this is, go to this file: \administrator\components\com_easysocial\models\privacy.php find this function: createFieldPrivacyItemsForUser and find this code and replace it. This fix will be included in the next releases.
$query[] = "INSERT INTO `#__social_privacy_items (`privacy_id`, `user_id`, `uid`, `type`, `value`)";

with
$query[] = "INSERT INTO `#__social_privacy_items` (`privacy_id`, `user_id`, `uid`, `type`, `value`)";


Hope this will help.
Thanks.
·
Wednesday, 24 September 2014 11:00
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Mohd, thank you for your reply, unfortunately now i get "Invalid Token" page after the first or the second step in 4 out of 5 tries. Very unstable.
Also, please advice regarding the registration method, i'd set the "User Activation" method to be applied for the default profile type, but the admin keeps getting an email with "approve" or "reject" buttons, is this normal? also, we got complains that users who have managed to register got a non valid activation code.

Many thanks in advance for your urgent fix of this,

Eldad
·
Wednesday, 24 September 2014 18:15
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi guys...
I'm also now getting a problem since upgrading to 1.3.5.
I tried to put in the fix you suggested above, but now when I try to create a new user (in this case using FB credentials) I get the following:
Warning

Registration failed: Registration failed: Table 'thegsn_gsndb.jos_social_privacy_items' doesn't exist SQL=select a.value from jos_social_privacy_items as a inner join jos_social_privacy as b on a.privacy_id = b.id where a.`user_id` = 305 and a.`type` = 'field' and b.`type` = 'field' and b.`rule` = 'joomla_email' union all select a.`value` from jos_social_privacy_map as a inner join jos_social_privacy as b on a.privacy_id = b.id where a.utype = 'user' and a.uid = 305 and b.`type` = 'field' and b.`rule` = 'joomla_email' union all select a.`value` from jos_social_privacy as a where a.`type` = 'field' and a.`rule` = 'joomla_email' limit 1

What's the fix for this?
Thanks
Dave
·
Wednesday, 24 September 2014 18:25
·
0 Likes
·
0 Votes
·
0 Comments
·
Dear Mohd, it seems to be working ok now, I also can't replicate the issue at the moment.
Many thanks,
Eldad
·
Wednesday, 24 September 2014 19:43
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi.
Yes, working for me now too.
Thanks for the fix.
Dave
·
Wednesday, 24 September 2014 19:54
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Eldad & Dave,

You're welcome. Glad to hear your issue have been resolved.
If you have anymore question, please don't hesitate to ask us and please create a new ticket. I will mark this ticket as resolved.

Thanks again and have a wonderful day.
·
Thursday, 25 September 2014 00:19
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post