A NOTE has been added to this issue. ====================================================================== http://www.dbmail.org/mantis/view.php?id=409 ====================================================================== Reported By: windowsrefund Assigned To: paul ====================================================================== Project: DBMail Issue ID: 409 Category: Database layer Reproducibility: always Severity: major Priority: normal Status: feedback target: ====================================================================== Date Submitted: 13-Sep-06 20:28 CEST Last Modified: 05-Oct-06 16:12 CEST ====================================================================== Summary: SQL script fails to create dbmail_envelope table Description: mysql version: 5.0.22-standard-log
====================================================================== ---------------------------------------------------------------------- windowsrefund - 13-Sep-06 20:31 ---------------------------------------------------------------------- This applies to 2268. Sorry for the typo. ---------------------------------------------------------------------- paul - 17-Sep-06 16:18 ---------------------------------------------------------------------- this any better: DROP TABLE IF EXISTS `dbmail_envelope`; CREATE TABLE `dbmail_envelope` ( `physmessage_id` bigint(20) NOT NULL default '0', `id` bigint(20) NOT NULL auto_increment, `envelope` text NOT NULL, PRIMARY KEY (`id`), KEY `physmessage_id` (`physmessage_id`), CONSTRAINT `dbmail_envelope_ibfk_1` FOREIGN KEY (`physmessage_id`) REFERENCES `dbmail_physmessage` (`id`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=latin1; ---------------------------------------------------------------------- aaron - 26-Sep-06 23:10 ---------------------------------------------------------------------- Paul, please be sure to put the contents of the 2_1_7-2_1_8 script into the main create_tables.sql. ---------------------------------------------------------------------- windowsrefund - 04-Oct-06 00:21 ---------------------------------------------------------------------- The constraint is causing this to fail on 5.0.22-standard-log For whatever reason, I was able to run this script successfully on 5.0.21-standard-log. ---------------------------------------------------------------------- alex - 04-Oct-06 18:37 ---------------------------------------------------------------------- The script should be changed to include a "set FOREIGN_KEY_CHECKS=0;" at the beginning and a set "FOREIGN_KEY_CHECKS=1;" at the end. That's all there is to it. ---------------------------------------------------------------------- windowsrefund - 04-Oct-06 19:02 ---------------------------------------------------------------------- This fix allowed me to create the table. However, now every time I run dbmail-util -by, it finds > 7000 missing envelope values Repairing DBMAIL for cached envelopes... Ok. Found [7882] missing envelope values. ......................................... Nothing gets inserted into the dbmail_envelope table. ---------------------------------------------------------------------- alex - 05-Oct-06 16:12 ---------------------------------------------------------------------- I can confirm this. It finds missing envelope values, claims to have fixed it, but on the next run displays the same error. And what's with the dots? Example: test:~ # dbmail-util -by Opening connection to database... Opening connection to authentication... Ok. Connected. Repairing DBMAIL for incorrect is_header flags... Ok. Found [0] incorrect is_header flags. Repairing DBMAIL for rfcsize field... Ok. Found [0] missing rfcsize values. Repairing DBMAIL for cached envelopes... Ok. Found [96] missing envelope values. ................................................................................................ Repairing DBMAIL for cached header values... Ok. Found [0] un-cached physmessages. Maintenance done. Errors were found and fixed. Try running dbmail-util again to confirm that the errors were repaired. test:~ # dbmail-util -by Opening connection to database... Opening connection to authentication... Ok. Connected. Repairing DBMAIL for incorrect is_header flags... Ok. Found [0] incorrect is_header flags. Repairing DBMAIL for rfcsize field... Ok. Found [0] missing rfcsize values. Repairing DBMAIL for cached envelopes... Ok. Found [96] missing envelope values. ................................................................................................ Repairing DBMAIL for cached header values... Ok. Found [0] un-cached physmessages. Maintenance done. Errors were found and fixed. Try running dbmail-util again to confirm that the errors were repaired. Issue History Date Modified Username Field Change ====================================================================== 13-Sep-06 20:28 windowsrefund New Issue 13-Sep-06 20:31 windowsrefund Note Added: 0001399 17-Sep-06 16:18 paul Note Added: 0001404 17-Sep-06 16:18 paul Status new => feedback 17-Sep-06 16:18 paul Status feedback => assigned 17-Sep-06 16:18 paul Assigned To => paul 26-Sep-06 23:10 aaron Note Added: 0001420 30-Sep-06 19:54 paul Status assigned => resolved 30-Sep-06 19:54 paul Resolution open => fixed 04-Oct-06 00:21 windowsrefund Status resolved => feedback 04-Oct-06 00:21 windowsrefund Resolution fixed => reopened 04-Oct-06 00:21 windowsrefund Note Added: 0001444 04-Oct-06 18:37 alex Note Added: 0001451 04-Oct-06 19:02 windowsrefund Note Added: 0001452 05-Oct-06 16:12 alex Note Added: 0001462 ======================================================================
