Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
Specify RETURNING columns explicitly, otherwise adding a new column would break the code
天舟9c65cab3c403
diff --git a/backend/store/member.go b/backend/store/member.goindex d169b7bd0c..78cb28e240 100644--- a/backend/store/member.go+++ b/backend/store/member.go@@ -232,7 +232,7 @@ func patchMember(ctx context.Context, tx *Tx, id int, patch *api.MemberPatch) (*UPDATE memberSET role = ?, updater_id = ?WHERE id = ?- RETURNING *+ RETURNING id, workspace_id, creator_id, created_ts, updater_id, updated_ts, role, principal_id`,member.Role,patch.UpdaterId,diff --git a/backend/store/principal.go b/backend/store/principal.goindex fd71d3dadd..f3dc059756 100644--- a/backend/store/principal.go+++ b/backend/store/principal.go@@ -124,7 +124,7 @@ func createPrincipal(ctx context.Context, tx *Tx, create *api.PrincipalCreate) (password_hash)VALUES (?, ?, ?, ?, ?, ?, ?)- RETURNING *+ RETURNING id, creator_id, created_ts, updater_id, updated_ts, status, type, name, email, password_hash`,create.CreatorId,create.CreatorId,@@ -251,7 +251,7 @@ func patchPrincipal(ctx context.Context, tx *Tx, id int, patch *api.PrincipalPatUPDATE principalSET name = ?, updater_id = ?WHERE id = ?- RETURNING *+ RETURNING id, creator_id, created_ts, updater_id, updated_ts, status, type, name, email, password_hash`,principal.Name,patch.UpdaterId,