Garbage collection of deleted CO fails because of cm_co_announcements fk

XMLWordPrintable

      The garbage collection job for a deleted CO failed with Finish Summary "SQLSTATE[23000]: Integrity constraint violation: 1451 Cannot delete or update a parent row: a foreign key constraint fails (`biocommons_registry_test`.`cm_co_announcements`, CONSTRAINT `cm_co_announcements_co_announcement_channel_id_fk` FOREIGN KEY (`co_an "

      (The rest is cut off).

      I removed the foreign key constraint manually using ALTER TABLE, deleted all rows from the cm_co_announcements table (they were all from the CO that was being deleted), and then added back the foreign key constraint with another ALTER TABLE command.

      I then rescheduled the garbage collection job and this time it ran to completion and the COs that were queued to be deleted were deleted.

      This happened with version 4.3.1.

            Assignee:
            Shayna Atkinson
            Reporter:
            Scott Koranda
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: