diff options
author | 2019-09-16 14:25:19 +0000 | |
---|---|---|
committer | 2019-09-16 14:25:19 +0000 | |
commit | 799f04c129b09d29ebd1b87092dea699a4174d11 (patch) | |
tree | f740a2d3cf767e479ae898c14b20c19cca63da1e /ms/blueprintsprocessor/application/src/main/resources/sql/schema-local.sql | |
parent | bfe3e8331c2d30a12ef7d0ea2e2edda5832f85ad (diff) | |
parent | 7d93d9fffffc0cb9a9f432c10797269b8fd1ebd0 (diff) |
Merge "Blueprintprocessor Table change."
Diffstat (limited to 'ms/blueprintsprocessor/application/src/main/resources/sql/schema-local.sql')
-rw-r--r-- | ms/blueprintsprocessor/application/src/main/resources/sql/schema-local.sql | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/ms/blueprintsprocessor/application/src/main/resources/sql/schema-local.sql b/ms/blueprintsprocessor/application/src/main/resources/sql/schema-local.sql index ad048b017..05df4200a 100644 --- a/ms/blueprintsprocessor/application/src/main/resources/sql/schema-local.sql +++ b/ms/blueprintsprocessor/application/src/main/resources/sql/schema-local.sql @@ -6,8 +6,8 @@ -- ----------------------------------------------------- -- table CONFIG_MODEL -- ----------------------------------------------------- -CREATE TABLE IF NOT EXISTS sdnctl.CONFIG_MODEL ( - config_model_id INT(11) NOT NULL AUTO_INCREMENT, +CREATE TABLE IF NOT EXISTS sdnctl.BLUEPRINT_MODEL ( + blueprint_model_id VARCHAR(50) NOT NULL, service_uuid VARCHAR(50) NULL DEFAULT NULL, distribution_id VARCHAR(50) NULL DEFAULT NULL, service_name VARCHAR(255) NULL DEFAULT NULL, @@ -27,25 +27,25 @@ CREATE TABLE IF NOT EXISTS sdnctl.CONFIG_MODEL ( published varchar(1) not null, updated_by varchar(100) not null, tags longtext null default null, - primary key PK_CONFIG_MODEL (config_model_id), - UNIQUE KEY UK_CONFIG_MODEL (artifact_name , artifact_version) + primary key PK_BLUEPRINT_MODEL (blueprint_model_id), + UNIQUE KEY UK_BLUEPRINT_MODEL (artifact_name , artifact_version) ) ENGINE=InnoDB; -- ----------------------------------------------------- -- table CONFIG_MODEL_CONTENT -- ----------------------------------------------------- -CREATE TABLE IF NOT EXISTS sdnctl.CONFIG_MODEL_CONTENT ( - config_model_content_id INT(11) NOT NULL AUTO_INCREMENT, - config_model_id INT NOT NULL, +CREATE TABLE IF NOT EXISTS sdnctl.BLUEPRINT_MODEL_CONTENT ( + blueprint_model_content_id VARCHAR(50) NOT NULL, + blueprint_model_id VARCHAR(50) NOT NULL, name VARCHAR(100) NOT NULL, content_type VARCHAR(50) NOT NULL, description LONGTEXT NULL DEFAULT NULL, updated_date DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, - content LONGTEXT NULL DEFAULT NULL, - PRIMARY KEY PK_CONFIG_MODEL_CONTENT (config_model_content_id), - UNIQUE KEY UK_CONFIG_MODEL_CONTENT (config_model_id, name, content_type), - FOREIGN KEY FK_CONFIG_MODEL_CONTENT (config_model_id) REFERENCES sdnctl.CONFIG_MODEL(config_model_id) ON DELETE CASCADE + content LONGBLOB NULL DEFAULT NULL, + PRIMARY KEY PK_BLUEPRINT_MODEL_CONTENT (blueprint_model_content_id), + UNIQUE KEY UK_BLUEPRINT_MODEL_CONTENT (blueprint_model_id, name, content_type), + FOREIGN KEY FK_BLUEPRINT_MODEL_CONTENT (blueprint_model_id) REFERENCES sdnctl.BLUEPRINT_MODEL(blueprint_model_id) ON DELETE CASCADE ) ENGINE=InnoDB; -- ----------------------------------------------------- |