CREATE TABLE IF NOT EXISTS `entities` ( `id` text PRIMARY KEY NOT NULL, `created_at` text NOT NULL, `updated_at` text NOT NULL, `deleted_at` text, `project_id` text NOT NULL REFERENCES `projects`(`id`), `name` text NOT NULL, `type` text NOT NULL DEFAULT 'other', `description` text NOT NULL DEFAULT '', `aliases` text NOT NULL DEFAULT '[]' ); --> statement-breakpoint CREATE INDEX IF NOT EXISTS `entities_project_id_idx` ON `entities` (`project_id`); --> statement-breakpoint CREATE INDEX IF NOT EXISTS `entities_name_idx` ON `entities` (`name`);