----- Nachricht von Sandino Araico Sánchez <sand...@sandino.net> ---------
     Datum: Thu, 12 Oct 2017 04:00:17 -0500
       Von: Sandino Araico Sánchez <sand...@sandino.net>
Antwort an: DBMail mailinglist <dbmail@dbmail.org>
   Betreff: Re: [Dbmail] Installations problems with dbmail 3.2.3
        An: DBMail mailinglist <dbmail@dbmail.org>, Ralph Ballier <ball...@mail.schule.de>

[..............]

 >> Thanks for your answer.

I now use 3.1.17. There is the same error message while set up the tables using "create_tables.mysql":

ERROR 1005 (HY000) at line 401: Can't create table `dbmail`.`dbmail_auto_replies` (errno: 121 "Duplicate key on write or update") MySQL error 1005 is an incorrect foreign key. In this case a duplicate key in dbmail_users.user_idnr.

You must fix all duplicate keys in dbmail_users (there might be more than one) before table dbmail_auto_replies  can be created .

Yes, you are right. I find two identical lines in "CREATE TABLE dbmail_auto_notifications" and in "CREATE TABLE dbmail_auto_replies" (see below).

But what do you mean with "fix it"? Shall I delete the words FOREIGN KEY? If yes, in the first or in the second CREATE statement? Or in both?

Thanks

Ralph

 CREATE TABLE dbmail_auto_notifications (
         user_idnr bigint(20) UNSIGNED NOT NULL,
         notify_address varchar(100) NOT NULL default '',
         INDEX user_idnr_index (user_idnr),
         FOREIGN KEY USER_IDNR_FK (USER_IDNR)
                REFERENCES dbmail_users (user_idnr) ON DELETE CASCADE ON UPDATE CASCADE
 ) ENGINE InnoDB DEFAULT CHARSET=utf8;
  
 DROP TABLE IF EXISTS dbmail_auto_replies;
 CREATE TABLE dbmail_auto_replies (
         user_idnr bigint(20) UNSIGNED DEFAULT '0' NOT NULL,
         start_date DATETIME NOT NULL,
         stop_date DATETIME NOT NULL,
         reply_body MEDIUMTEXT,
         INDEX user_idnr_index (user_idnr),
         FOREIGN KEY USER_IDNR_FK (USER_IDNR)
                REFERENCES dbmail_users (user_idnr) ON DELETE CASCADE ON UPDATE CASCADE
 ) ENGINE InnoDB DEFAULT CHARSET=utf8;
  

 
   
_______________________________________________
DBmail mailing list
DBmail@dbmail.org
http://lists.nfg.nl/mailman/listinfo/dbmail

Reply via email to