Skip to content

Commit

Permalink
fix(sql): add cascade on delete feasibility
Browse files Browse the repository at this point in the history
  • Loading branch information
ThomasDos committed Jul 16, 2024
1 parent 87a2b31 commit 4ffb725
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@ ALTER TABLE "feasibility_uploaded_pdf" ADD CONSTRAINT "feasibility_uploaded_pdf_
ALTER TABLE "feasibility_uploaded_pdf" ADD CONSTRAINT "feasibility_uploaded_pdf_certificate_of_attendance_file_id_fkey" FOREIGN KEY ("certificate_of_attendance_file_id") REFERENCES "file"("id") ON DELETE SET NULL ON UPDATE CASCADE;

-- AddForeignKey
ALTER TABLE "feasibility_uploaded_pdf" ADD CONSTRAINT "feasibility_uploaded_pdf_feasibility_id_fkey" FOREIGN KEY ("feasibility_id") REFERENCES "feasibility"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
ALTER TABLE "feasibility_uploaded_pdf" ADD CONSTRAINT "feasibility_uploaded_pdf_feasibility_id_fkey" FOREIGN KEY ("feasibility_id") REFERENCES "feasibility"("id") ON DELETE CASCADE ON UPDATE CASCADE;

-- AddForeignKey
ALTER TABLE "dematerialized_feasibility_file" ADD CONSTRAINT "dematerialized_feasibility_file_feasibility_id_fkey" FOREIGN KEY ("feasibility_id") REFERENCES "feasibility"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
ALTER TABLE "dematerialized_feasibility_file" ADD CONSTRAINT "dematerialized_feasibility_file_feasibility_id_fkey" FOREIGN KEY ("feasibility_id") REFERENCES "feasibility"("id") ON DELETE CASCADE ON UPDATE CASCADE;

-- AlterTable
ALTER TABLE "feasibility"
Expand Down

0 comments on commit 4ffb725

Please sign in to comment.