diff --git a/tapdb/sqlc/migrations/000007_universe.up.sql b/tapdb/sqlc/migrations/000007_universe.up.sql index ededb30bc..78eb29a7a 100644 --- a/tapdb/sqlc/migrations/000007_universe.up.sql +++ b/tapdb/sqlc/migrations/000007_universe.up.sql @@ -107,11 +107,11 @@ CREATE TABLE IF NOT EXISTS federation_global_sync_config ( CREATE TABLE IF NOT EXISTS federation_uni_sync_config ( -- This field contains the byte serialized ID of the asset that this -- configuration applies to. - asset_id BLOB, -- CHECK(length(asset_id) = 32) NULL, + asset_id BLOB CHECK(length(asset_id) = 32) NULL, -- This field contains the byte serialized group key public key of the asset -- group that this configuration applies to. - group_key BLOB, -- CHECK(LENGTH(group_key) = 32) NULL, + group_key BLOB CHECK(LENGTH(group_key) = 32) NULL, -- This field is an enum representing the proof type stored in the given -- universe. @@ -125,11 +125,11 @@ CREATE TABLE IF NOT EXISTS federation_uni_sync_config ( -- should accept remote proof export via federation sync. allow_sync_export BOOLEAN NOT NULL, --- -- Both the asset ID and group key cannot be null at the same time. --- CHECK ( --- (asset_id IS NOT NULL AND group_key IS NULL) OR --- (asset_id IS NULL AND group_key IS NOT NULL) --- ), + -- Both the asset ID and group key cannot be null at the same time. + CHECK ( + (asset_id IS NOT NULL AND group_key IS NULL) OR + (asset_id IS NULL AND group_key IS NOT NULL) + ), -- The primary key is the universe identifier: the asset ID and group key. UNIQUE (asset_id, group_key, proof_type)