diff --git a/core/store/migrate/migrations/0215_functions_subscriptions.sql b/core/store/migrate/migrations/0215_functions_subscriptions.sql new file mode 100644 index 00000000000..e5b186506c3 --- /dev/null +++ b/core/store/migrate/migrations/0215_functions_subscriptions.sql @@ -0,0 +1,17 @@ +-- +goose Up +-- +goose StatementBegin +CREATE TABLE functions_subscriptions( + subscription_id bigint PRIMARY KEY, + owner_address bytea CHECK (octet_length(owner_address) = 20) NOT NULL, + balance bigint, + blocked_balance bigint, + proposed_owner bytea, + consumers bytea[], + flags bytea +); +-- +goose StatementEnd + +-- +goose Down +-- +goose StatementBegin +DROP TABLE IF EXISTS functions_subscriptions; +-- +goose StatementEnd diff --git a/core/store/migrate/migrations/0216_functions_allowlist.sql b/core/store/migrate/migrations/0216_functions_allowlist.sql new file mode 100644 index 00000000000..fc7541cd67f --- /dev/null +++ b/core/store/migrate/migrations/0216_functions_allowlist.sql @@ -0,0 +1,11 @@ +-- +goose Up +-- +goose StatementBegin +CREATE TABLE functions_allowlist( + allowed_address bytea CHECK (octet_length(allowed_address) = 20) PRIMARY KEY +); +-- +goose StatementEnd + +-- +goose Down +-- +goose StatementBegin +DROP TABLE IF EXISTS functions_allowlist; +-- +goose StatementEnd