From e234d3535c363664902dffe89a2c61ddbc037da4 Mon Sep 17 00:00:00 2001
From: MohamedBassem <me@mbassem.com>
Date: Fri, 23 Feb 2024 19:27:31 +0000
Subject: db: Migrate from prisma to drizzle

---
 .../20240206000813_add_links/migration.sql         | 43 ----------------------
 1 file changed, 43 deletions(-)
 delete mode 100644 packages/db/prisma/migrations/20240206000813_add_links/migration.sql

(limited to 'packages/db/prisma/migrations/20240206000813_add_links/migration.sql')

diff --git a/packages/db/prisma/migrations/20240206000813_add_links/migration.sql b/packages/db/prisma/migrations/20240206000813_add_links/migration.sql
deleted file mode 100644
index 38c8d938..00000000
--- a/packages/db/prisma/migrations/20240206000813_add_links/migration.sql
+++ /dev/null
@@ -1,43 +0,0 @@
--- CreateTable
-CREATE TABLE "BookmarkedLink" (
-    "id" TEXT NOT NULL PRIMARY KEY,
-    "url" TEXT NOT NULL,
-    "createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
-    "userId" TEXT NOT NULL,
-    CONSTRAINT "BookmarkedLink_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User" ("id") ON DELETE CASCADE ON UPDATE CASCADE
-);
-
--- CreateTable
-CREATE TABLE "BookmarkedLinkDetails" (
-    "id" TEXT NOT NULL PRIMARY KEY,
-    "title" TEXT NOT NULL,
-    "description" TEXT NOT NULL,
-    "imageUrl" TEXT NOT NULL,
-    "createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
-    CONSTRAINT "BookmarkedLinkDetails_id_fkey" FOREIGN KEY ("id") REFERENCES "BookmarkedLink" ("id") ON DELETE CASCADE ON UPDATE CASCADE
-);
-
--- CreateTable
-CREATE TABLE "BookmarkTags" (
-    "id" TEXT NOT NULL PRIMARY KEY,
-    "name" TEXT NOT NULL,
-    "createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
-    "userId" TEXT NOT NULL,
-    CONSTRAINT "BookmarkTags_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User" ("id") ON DELETE CASCADE ON UPDATE CASCADE
-);
-
--- CreateTable
-CREATE TABLE "TagsOnLinks" (
-    "linkId" TEXT NOT NULL,
-    "tagId" TEXT NOT NULL,
-    "attachedAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
-    "bookmarkTagsId" TEXT NOT NULL,
-    CONSTRAINT "TagsOnLinks_linkId_fkey" FOREIGN KEY ("linkId") REFERENCES "BookmarkedLink" ("id") ON DELETE CASCADE ON UPDATE CASCADE,
-    CONSTRAINT "TagsOnLinks_tagId_fkey" FOREIGN KEY ("tagId") REFERENCES "BookmarkTags" ("id") ON DELETE CASCADE ON UPDATE CASCADE
-);
-
--- CreateIndex
-CREATE UNIQUE INDEX "BookmarkTags_name_key" ON "BookmarkTags"("name");
-
--- CreateIndex
-CREATE UNIQUE INDEX "TagsOnLinks_linkId_tagId_key" ON "TagsOnLinks"("linkId", "tagId");
-- 
cgit v1.3-1-g0d28

