Files
base/database/migrations/20260226000000_specialist_roles.sql
2026-04-10 18:25:21 +03:30

14 lines
551 B
SQL

-- Create "profile_roles" table (profiles.role_id references this)
CREATE TABLE "public"."profile_roles" (
"id" uuid NOT NULL DEFAULT gen_random_uuid(),
"title" text NOT NULL,
"status" text NOT NULL DEFAULT 'active',
"created_at" timestamptz NOT NULL DEFAULT now(),
"updated_at" timestamptz NOT NULL DEFAULT now(),
"deleted_at" timestamptz NULL,
PRIMARY KEY ("id")
);
CREATE INDEX "profile_roles_status_idx" ON "public"."profile_roles" ("status");
CREATE INDEX "profile_roles_deleted_at_idx" ON "public"."profile_roles" ("deleted_at");