Browse Source

chore(iot-hub): move iot_hub_installed_item migration to lts schema_update

Relocate the iot_hub_installed_item CREATE TABLE statement from the
basic schema_update.sql to the LTS cumulative schema_update.sql, where
it belongs for this LTS line.
pull/15547/head
Igor Kulikov 3 months ago
parent
commit
a39dd47ab8
  1. 16
      application/src/main/data/upgrade/basic/schema_update.sql
  2. 16
      application/src/main/data/upgrade/lts/schema_update.sql

16
application/src/main/data/upgrade/basic/schema_update.sql

@ -80,19 +80,3 @@ DROP TABLE IF EXISTS calculated_field_link;
ANALYZE calculated_field;
-- REMOVAL OF CALCULATED FIELD LINKS PERSISTENCE END
-- IOT HUB INSTALLED ITEM START
CREATE TABLE IF NOT EXISTS iot_hub_installed_item (
id UUID NOT NULL PRIMARY KEY,
created_time BIGINT NOT NULL,
tenant_id UUID NOT NULL,
item_id UUID NOT NULL,
item_version_id UUID NOT NULL,
item_name VARCHAR NOT NULL,
item_type VARCHAR NOT NULL,
version VARCHAR NOT NULL,
descriptor JSONB NOT NULL
);
-- IOT HUB INSTALLED ITEM END

16
application/src/main/data/upgrade/lts/schema_update.sql

@ -23,3 +23,19 @@
ALTER TABLE calculated_field ADD COLUMN IF NOT EXISTS additional_info varchar;
-- CALCULATED FIELD ADDITIONAL INFO ADDITION END
-- IOT HUB INSTALLED ITEM START
CREATE TABLE IF NOT EXISTS iot_hub_installed_item (
id UUID NOT NULL PRIMARY KEY,
created_time BIGINT NOT NULL,
tenant_id UUID NOT NULL,
item_id UUID NOT NULL,
item_version_id UUID NOT NULL,
item_name VARCHAR NOT NULL,
item_type VARCHAR NOT NULL,
version VARCHAR NOT NULL,
descriptor JSONB NOT NULL
);
-- IOT HUB INSTALLED ITEM END

Loading…
Cancel
Save