SQL error saving a Contact
- Status
- Closed
- Subject
- SQL error saving a Contact
- Version
- 12.x
- Category
- Error
- Feature
- Contact (address book)
- Resolution status
- New
- Submitted by
- Telesight
- Volunteered to solve
- Jean-Marc Libs
- Lastmod by
- Jean-Marc Libs
- Rating
- Description
As a registered user I try to create a contact, I click on the save button and then I get the following page with this error (By the way the contact is saved):
The following error message was returned:
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 'AS x FROM `tiki_webmail_contacts_ext` AS x LEFT JOIN `tiki_webmail_contacts_fiel' at line 1
The query was:
DELETE `tiki_webmail_contacts_ext`.* AS x FROM `tiki_webmail_contacts_ext` AS x LEFT JOIN `tiki_webmail_contacts_fields` AS f ON x.`fieldId`=f.`fieldId`WHERE x.`contactId`=? AND f.`flagsPublic`='n' AND f.`user`=?Values:
1. 2
2. John DoeThe built query was likely:
DELETE `tiki_webmail_contacts_ext`.* AS x FROM `tiki_webmail_contacts_ext` AS x LEFT JOIN `tiki_webmail_contacts_fields` AS f ON x.`fieldId`=f.`fieldId`WHERE x.`contactId`='2' AND f.`flagsPublic`='n' AND f.`user`='John Doe'
The extra fields like "City" and so on, are not saved.
Logged in as a admin I do not get this fault (not on my own installation nor on the show.tikiwiki.org)
I have seen this error in version 11 too, but did not pay attention to it because it was my first use of Tiki.- Solution
The SQL error made the whole site get in error mode when a normal user adds a contact.
SQL query obviously wrong and easy to fix.Funny thing is, no error in Tiki 9.x, yet the query is the same there.
Committed revision 49381. Thank you for the report
- Importance
- 10 high
- Easy to solve?
- 9
- Priority
- 90
- Demonstrate Bug on Tiki 19+
-
This bug has been demonstrated on show2.tiki.org
Please demonstrate your bug on show2.tiki.org
Show.tiki.org is not configured properlyThe public/private keys configured to connect to show2.tiki.org were not accepted. Please make sure you are using RSA keys. Thanks.
- Demonstrate Bug (older Tiki versions)
-
This bug has been demonstrated on show.tikiwiki.org
Please demonstrate your bug on show.tikiwiki.org
Show.tiki.org is not configured properlyThe public/private keys configured to connect to show.tikiwiki.org were not accepted. Please make sure you are using RSA keys. Thanks.
- Ticket ID
- 5097
- Created
- Tuesday 14 January, 2014 13:03:39 UTC
by Telesight - LastModif
- Tuesday 14 January, 2014 20:40:25 UTC