noteshare.space/server/prisma/migrations/20220825142403_add_embed_table/migration.sql
Maxime Cannoodt e9956486fd add table
2022-08-25 16:24:18 +02:00

11 lines
378 B
SQL

-- CreateTable
CREATE TABLE "EncryptedEmbed" (
"id" TEXT NOT NULL PRIMARY KEY,
"note_id" TEXT NOT NULL,
"embed_id" TEXT NOT NULL,
"ciphertext" BLOB NOT NULL,
"hmac" TEXT NOT NULL,
"size_bytes" INTEGER NOT NULL,
CONSTRAINT "EncryptedEmbed_note_id_fkey" FOREIGN KEY ("note_id") REFERENCES "EncryptedNote" ("id") ON DELETE RESTRICT ON UPDATE CASCADE
);