taskcafe/migrations/0034_add-cascade-delete-to_project_team_id_fkey.up.sql

7 lines
188 B
MySQL
Raw Permalink Normal View History

ALTER TABLE project DROP CONSTRAINT project_team_id_fkey;
ALTER TABLE project
ADD CONSTRAINT project_team_id_fkey
FOREIGN KEY (team_id)
REFERENCES team(team_id)
ON DELETE CASCADE;