Forum OpenACS Development: missing index and foreign key constraints on cr_item_publish_audit fixed (postgres)
-- Clear the audit delete from cr_item_publish_audit where old_revision = delete__revision_id or new_revision = delete__revision_id;but there was no index on either
new_revision. Therefore, on substantial databases, deleting a revision could took many seconds.
content_item__delwas not affected by this slowness, since it deletes the audit-trail items via
Furthermore, the foreign key from
cr_item_publish_audit (item_id) to
cr_items was missing. Therefore it could contain item_ids not present in
cr_items. Added as well foreign keys for
I have fixed these issues on cvs head.