summaryrefslogtreecommitdiffstats
path: root/schema/mysql-legacy-changes/upgrade_55.sql
blob: 4ad6feb264b0694acf770b728afa0a1c77a0adbe (plain)
1
2
3
4
5
6
7
8
ALTER TABLE icinga_zone
  DROP FOREIGN KEY icinga_zone_parent_zone,
  CHANGE parent_zone_id parent_id INT(10) UNSIGNED DEFAULT NULL,
  ADD CONSTRAINT icinga_zone_parent
    FOREIGN KEY parent_zone (parent_id)
    REFERENCES icinga_zone (id)
    ON DELETE RESTRICT
    ON UPDATE CASCADE;