mirror of
https://github.com/Floriansylvain/SnippetsManager.git
synced 2026-08-19 11:43:15 +02:00
Made category optional on Snippet table
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
-- DropForeignKey
|
||||
ALTER TABLE `Snippet` DROP FOREIGN KEY `Snippet_category_id_fkey`;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE `Snippet` MODIFY `category_id` INTEGER NULL;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE `Snippet` ADD CONSTRAINT `Snippet_category_id_fkey` FOREIGN KEY (`category_id`) REFERENCES `Category`(`id`) ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
Reference in New Issue
Block a user