mirror of
https://github.com/Sonny93/my-links.git
synced 2025-12-09 15:05:35 +00:00
12 lines
387 B
SQL
12 lines
387 B
SQL
/*
|
|
Warnings:
|
|
|
|
- Added the required column `authorId` to the `link` table without a default value. This is not possible if the table is not empty.
|
|
|
|
*/
|
|
-- AlterTable
|
|
ALTER TABLE `link` ADD COLUMN `authorId` INTEGER NOT NULL;
|
|
|
|
-- AddForeignKey
|
|
ALTER TABLE `link` ADD CONSTRAINT `link_authorId_fkey` FOREIGN KEY (`authorId`) REFERENCES `user`(`id`) ON DELETE RESTRICT ON UPDATE CASCADE;
|