pkgs/db/drizzle/20260629171950_dizzy_expediter/migration.sql (view raw)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
CREATE TABLE `bugs` ( `id` integer PRIMARY KEY AUTOINCREMENT, `guild_id` integer NOT NULL, `actor_id` integer NOT NULL, `bug_number` integer NOT NULL, `status` text, `title` text NOT NULL, `description` text NOT NULL, `affected_projects` text DEFAULT '[]' NOT NULL, `sent` integer DEFAULT false NOT NULL, `message_id` text, `thread_id` text, `created_at` integer DEFAULT (unixepoch()) NOT NULL, `updated_at` integer DEFAULT (unixepoch()) NOT NULL, `closed_at` integer, CONSTRAINT `fk_bugs_guild_id_guilds_id_fk` FOREIGN KEY (`guild_id`) REFERENCES `guilds`(`id`) ON DELETE CASCADE, CONSTRAINT `fk_bugs_actor_id_actors_id_fk` FOREIGN KEY (`actor_id`) REFERENCES `actors`(`id`) ON DELETE CASCADE ); |