I just tried to update from 5.66.0 to 5.68.0 and it failed with the following message:
Error executing task "Update civicrm_mailing_event_queue to permit deleting records from civicrm_mailing_job"
In FiveSixtySeven.php line 136:
db error messageconstraint violationmessage DB Error: constraint violation
sql
user info
ALTER TABLE `civicrm_mailing_event_queue`
ADD CONSTRAINT `FK_civicrm_mailing_event_queue_job_id`
FOREIGN KEY (`job_id`)
REFERENCES `civicrm_mailing_job`(`id`) ON DELETE SET NULL
[nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`database_name`.`#sql-alter-21481d-19e5278`, CONSTRAINT `FK_civicrm_mailing_event_queue_job_id` FO
REIGN KEY (`job_id`) REFERENCES `civicrm_mailing_job` (`id`) ON DELETE SET NULL)]
debug info DB Error: constraint violation
debug info
ALTER TABLE `civicrm_mailing_event_queue`
ADD CONSTRAINT `FK_civicrm_mailing_event_queue_job_id`
FOREIGN KEY (`job_id`)
REFERENCES `civicrm_mailing_job`(`id`) ON DELETE SET NULL
[nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`database_name`.`#sql-alter-21481d-19e5278`, CONSTRAINT `FK_civicrm_mailing_event_queue_job_id` FO
REIGN KEY (`job_id`) REFERENCES `civicrm_mailing_job` (`id`) ON DELETE SET NULL)]
I've managed to get the site live again using cv upgrade:db --skip
but now I have a bunch of errors in System Status.
Under 'Scheduled Job Failures' I have:
Finished execution of Rebuild Smart Group Cache with result: Failure, Error message: DB Error: no such field
Under 'Outdated tokens in use' I have:
Please review your event_offline_receipt message template and remove references to the token {$dataArray} as it has been replaced by {found within $participants}
Please review your event_offline_receipt message template and remove references to the token {$paidBy} as it has been replaced by {contribution.payment_instrument_id:label}
Please review your event_offline_receipt message template and remove references to the token {$totalTaxAmount} as it has been replaced by {contribution.tax_amount}
Please review your event_offline_receipt message template and remove references to the token {$amount} as it has been replaced by {found within $participants}
Please review your event_offline_receipt message template and remove references to the token {$checkNumber} as it has been replaced by {contribution.check_number}
Please review your event_offline_receipt message template and remove references to the token {$register_date} as it has been replaced by {participant.register_date}
Please review your event_offline_receipt message template and remove references to the token {$receive_date} as it has been replaced by {contribution.receive_date}
Please review your event_offline_receipt message template and remove references to the token {$is_pay_later} as it has been replaced by {contribution.is_pay_later}
Please review your event_offline_receipt message template and remove references to the token {$totalAmount} as it has been replaced by {contribution.total_amount}
Please review your event_offline_receipt message template and remove references to the token {$location} as it has been replaced by {event.location}
Please review your event_offline_receipt message template and remove references to the token {$isShowLocation} as it has been replaced by {event.is_show_location|boolean}
Please review your event_offline_receipt message template and remove references to the token {$event.participant_role} as it has been replaced by {participant.role_id:label}
Please review your event_offline_receipt message template and remove references to the token {balanceAmount} as it has been replaced by {contribution.balance_amount}
Please review your event_offline_receipt message template and remove references to the token {$financialTypeName} as it has been replaced by {contribution.financial_type_id:label}
Please review your event_offline_receipt message template and remove references to the token {$trxn_id} as it has been replaced by {contribution.trxn_id}
Please review your event_online_receipt message template and remove references to the token {`$participant.id`} as it has been replaced by {participant.id}
And under the upgrade headings it still shows 5.66.1 through 5.68.0 as upgrade options, even though the 'powered by' footer at the bottom successfully shows 5.68.0.
How do I get everything back to full working order?
Running on Drupal 7.99.