Initial commit: LACA parking management system
This commit is contained in:
21
backend/prisma/migrations/20241027172209_/migration.sql
Normal file
21
backend/prisma/migrations/20241027172209_/migration.sql
Normal file
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
Warnings:
|
||||
|
||||
- You are about to alter the column `close` on the `Slot` table. The data in that column could be lost. The data in that column will be cast from `VarChar` to `VarChar(1)`.
|
||||
- You are about to alter the column `open` on the `Slot` table. The data in that column could be lost. The data in that column will be cast from `VarChar` to `VarChar(1)`.
|
||||
|
||||
*/
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "Slot" DROP CONSTRAINT "Slot_tenantId_fkey";
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Slot" ADD COLUMN "userId" INTEGER,
|
||||
ALTER COLUMN "tenantId" DROP NOT NULL,
|
||||
ALTER COLUMN "close" SET DATA TYPE VARCHAR(5),
|
||||
ALTER COLUMN "open" SET DATA TYPE VARCHAR(5);
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Slot" ADD CONSTRAINT "Slot_tenantId_fkey" FOREIGN KEY ("tenantId") REFERENCES "Tenant"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Slot" ADD CONSTRAINT "Slot_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
Reference in New Issue
Block a user