You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
db-schema/db_scripts/diff/15787.up

10 lines
392 B

USE provisioning;
SET autocommit=0;
DELETE from voip_preferences_enum where preference_id NOT IN (select id from voip_preferences);
ALTER TABLE voip_preferences_enum DROP FOREIGN KEY `voip_preferences_enum_ibfk_1`;
ALTER TABLE voip_preferences_enum ADD CONSTRAINT `pref_id_fk` FOREIGN KEY (`preference_id`) REFERENCES `voip_preferences` (`id`) ON UPDATE CASCADE ON DELETE CASCADE;
COMMIT;