From fa3b15f6e1ace4d1b52e4967a517ef4644138671 Mon Sep 17 00:00:00 2001 From: Zack Fu Zi Xiang Date: Tue, 5 Nov 2024 12:54:22 +0800 Subject: [PATCH] fix: migration script --- migrations/20241101063559_af_workspace_namespace.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/migrations/20241101063559_af_workspace_namespace.sql b/migrations/20241101063559_af_workspace_namespace.sql index 342d3272b..a5dbc8cf1 100644 --- a/migrations/20241101063559_af_workspace_namespace.sql +++ b/migrations/20241101063559_af_workspace_namespace.sql @@ -53,8 +53,8 @@ FOR EACH ROW EXECUTE FUNCTION create_workspace_namespace(); -- Insert existing workspace records into `af_workspace_namespace` -INSERT INTO af_workspace_namespace (namespace, workspace_id) -SELECT publish_namespace, workspace_id +INSERT INTO af_workspace_namespace (namespace, workspace_id, is_original) +SELECT publish_namespace, workspace_id, TRUE FROM af_workspace ON CONFLICT (namespace) DO NOTHING; -- if there happens to be a workspace creation during migration