Add migration to ensure behavior of access_log FK "access_log_FK_1"
|Assignee:||José Raddaoui Marín||% Done:|
|Category:||Installation||Estimated time:||2.00 hours|
|Target version:||Release 2.0.0|
|Google Code Legacy ID:||Tested version:|
Radda, remember the change in arMigration0096 to get the FK doing cascade updates? We need to add that change as a new migration step.
It should look like this:
ALTER TABLE `access_log` DROP FOREIGN KEY `access_log_FK_1`; ALTER TABLE `access_log` ADD CONSTRAINT `access_log_FK_1` FOREIGN KEY (`object_id`) REFERENCES `object` (`id`) ON DELETE CASCADE ON UPDATE RESTRICT;
But maybe there is a better way to update existing FK's, I dunno.
Remember to bump the db version also in the 1.x branch and add the class in both branches as we need 1.x users to be up to date even if the db change targets only 2.x.