aboutsummaryrefslogtreecommitdiff
path: root/apps/web/migrations/0003_solid_boom_boom.sql
diff options
context:
space:
mode:
Diffstat (limited to 'apps/web/migrations/0003_solid_boom_boom.sql')
-rw-r--r--apps/web/migrations/0003_solid_boom_boom.sql10
1 files changed, 10 insertions, 0 deletions
diff --git a/apps/web/migrations/0003_solid_boom_boom.sql b/apps/web/migrations/0003_solid_boom_boom.sql
new file mode 100644
index 00000000..da4aa94b
--- /dev/null
+++ b/apps/web/migrations/0003_solid_boom_boom.sql
@@ -0,0 +1,10 @@
+CREATE TABLE `canvas` (
+ `id` text PRIMARY KEY NOT NULL,
+ `title` text DEFAULT 'Untitled' NOT NULL,
+ `description` text DEFAULT 'Untitled' NOT NULL,
+ `url` text DEFAULT '' NOT NULL,
+ `userId` text NOT NULL,
+ FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE cascade
+);
+--> statement-breakpoint
+CREATE INDEX `canvas_user_userId` ON `canvas` (`userId`); \ No newline at end of file