fix: add cascade delete to task comment & activity rows
This commit is contained in:
parent
66c603de75
commit
9c051c51a6
@ -0,0 +1,13 @@
|
|||||||
|
ALTER TABLE task_activity DROP CONSTRAINT task_activity_task_id_fkey;
|
||||||
|
ALTER TABLE task_activity
|
||||||
|
ADD CONSTRAINT task_activity_task_id_fkey
|
||||||
|
FOREIGN KEY (task_id)
|
||||||
|
REFERENCES task(task_id)
|
||||||
|
ON DELETE CASCADE;
|
||||||
|
|
||||||
|
ALTER TABLE task_comment DROP CONSTRAINT task_comment_task_id_fkey;
|
||||||
|
ALTER TABLE task_comment
|
||||||
|
ADD CONSTRAINT task_comment_task_id_fkey
|
||||||
|
FOREIGN KEY (task_id)
|
||||||
|
REFERENCES task(task_id)
|
||||||
|
ON DELETE CASCADE;
|
Loading…
Reference in New Issue
Block a user