Roundcube Community Forum

Third Party Contributions => API Based Plugins => Topic started by: cbrace on May 03, 2011, 03:42:41 AM

Title: automatic addressbook plugin: mysql error
Post by: cbrace on May 03, 2011, 03:42:41 AM
Hi all,

I am trying to install the automatic addressbook plugin under RC v0.5.2, however I encounter an error trying to initialize the MySQL database.

In phpMyAdmin, I paste the following code (the contents of roundcube/plugins/automatic_addressbook/SQL/mysql.initial.sql) into the SQL tab:
 
CREATE TABLE `collected_contacts` (
 `contact_id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT,
 `changed` datetime NOT NULL DEFAULT '1000-01-01 00:00:00',
 `del` tinyint(1) NOT NULL DEFAULT '0',
 `name` varchar(128) NOT NULL,
 `email` varchar(128) NOT NULL,
 `firstname` varchar(128) NOT NULL,
 `surname` varchar(128) NOT NULL,
 `vcard` text NULL,
 `user_id` int(10) UNSIGNED NOT NULL DEFAULT '0',
 PRIMARY KEY(`contact_id`),
 INDEX `user_collected_contacts_index` (`user_id`,`email`),
 CONSTRAINT `user_id_fk_contacts` FOREIGN KEY (`user_id`)
   REFERENCES `users`(`user_id`)
   --!40008
   --ON DELETE CASCADE
   --ON UPDATE CASCADE
);
Upon executing this, I see this error message:
#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 '--!40008 --ON DELETE CASCADE --ON UPDATE CASCADE )' at line 15
Any ideas what is going wrong here? I have MySQL 5.5 installed.

Thanks.
Title: automatic addressbook plugin: mysql error
Post by: spid3r on May 08, 2011, 10:24:59 AM
did you find the solution ? i don't get it either... :( my sql-fu is weak
Title: automatic addressbook plugin: mysql error
Post by: cbrace on May 08, 2011, 10:26:45 AM
Not yet, still hoping an SQL guru will turn up here some time ;)
Title: automatic addressbook plugin: mysql error
Post by: aaareg on May 10, 2011, 09:31:06 PM
So the answer was given
Linguarde - Client for Google Translator - Free Translate (http://www.linguarde.com)
Title: automatic addressbook plugin: mysql error
Post by: JocelynD on August 27, 2011, 09:27:55 AM
Should be fixed in latest SVN by now, see Roundcube plugin(s) - Anomalie #23: MySQL - #1005 - Can't create table - Redmine (http://code.crapouillou.net/issues/23)