Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
feat: add activity.container_id CHECK container_id > 0 (#728)
tianzhoue712dcfd912b
diff --git a/store/migration/10001__init_schema.sql b/store/migration/10001__init_schema.sqlindex 3b88eaab6a..994f4ccd50 100644--- a/store/migration/10001__init_schema.sql+++ b/store/migration/10001__init_schema.sql@@ -244,7 +244,6 @@ CREATE TABLE project_webhook (type TEXT NOT NULL CHECK (type LIKE 'bb.plugin.webhook.%'),name TEXT NOT NULL,url TEXT NOT NULL,- -- Comma separated list of activity triggers.activity_list TEXT ARRAY NOT NULL);@@ -751,8 +750,7 @@ CREATE TABLE activity (created_ts BIGINT NOT NULL DEFAULT extract(epoch from now()),updater_id INTEGER NOT NULL REFERENCES principal (id),updated_ts BIGINT NOT NULL DEFAULT extract(epoch from now()),- -- container_id is not zero.- container_id INTEGER NOT NULL,+ container_id INTEGER NOT NULL CHECK (container_id > 0),type TEXT NOT NULL CHECK (type LIKE 'bb.%'),level TEXT NOT NULL CHECK (level IN ('INFO', 'WARN', 'ERROR')),comment TEXT NOT NULL DEFAULT '',