refactor: 统一数据库约束维护位置
All checks were successful
ci/woodpecker/push/my-first-workflow Pipeline was successful
All checks were successful
ci/woodpecker/push/my-first-workflow Pipeline was successful
This commit is contained in:
@@ -19,12 +19,7 @@ CREATE TABLE IF NOT EXISTS config_spt (
|
||||
description TEXT NOT NULL DEFAULT ''
|
||||
);
|
||||
|
||||
ALTER TABLE config_spt DROP CONSTRAINT IF EXISTS idx_config_spt_task_id;
|
||||
DROP INDEX IF EXISTS idx_config_spt_task_id;
|
||||
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS idx_config_spt_task_id
|
||||
ON config_spt(task_id)
|
||||
WHERE deleted_at IS NULL;
|
||||
-- task_id 唯一约束统一在 约束类.sql 中维护。
|
||||
|
||||
ALTER TABLE config_spt DROP COLUMN IF EXISTS seat_id;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user