From 776c4819908805507ae9d7b5d3c89d3c829b08a4 Mon Sep 17 00:00:00 2001 From: Dan Timoney Date: Wed, 6 May 2020 12:47:53 -0400 Subject: Invalid SQL in db init script MySQL allows AUTO_INCREMENT to take args indicating initial value and offset. MariaDB AUTO_INCREMENT is not as flexible - you can specify initial value , but offset is a system-wide parameter (default 1, but can be overridden in my.conf config file). Changed database script to use AUTO_INCREMENT without (0,100), which will cause those fields to start at value 0 and increment by 1. Change-Id: Icc6793290082d455f9de1bd838a6ad8d71d66afa Issue-ID: CCSDK-2360 Signed-off-by: Dan Timoney --- .../db/changelog/scripts/rel_18_10/create_base_tables.sql | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'ms/neng/src/main/resources/db/changelog') diff --git a/ms/neng/src/main/resources/db/changelog/scripts/rel_18_10/create_base_tables.sql b/ms/neng/src/main/resources/db/changelog/scripts/rel_18_10/create_base_tables.sql index afb37437..650051a5 100644 --- a/ms/neng/src/main/resources/db/changelog/scripts/rel_18_10/create_base_tables.sql +++ b/ms/neng/src/main/resources/db/changelog/scripts/rel_18_10/create_base_tables.sql @@ -1,7 +1,7 @@ --liquibase formatted sql --changeset template_table:18_10.create_tables_p1.sql -CREATE TABLE GENERATED_NAME (GENERATED_NAME_ID INTEGER PRIMARY KEY AUTO_INCREMENT(0,100), +CREATE TABLE GENERATED_NAME (GENERATED_NAME_ID INTEGER PRIMARY KEY AUTO_INCREMENT, EXTERNAL_ID VARCHAR(500) NOT NULL COMMENT 'Key sent by SDNC', SEQUNCE_NUMBER INTEGER COMMENT 'Sequence number used for this name', SEQUENCE_NUMBER_ENC VARCHAR(100) COMMENT 'Alpha numeric equivalent of sequence_number column', @@ -16,7 +16,7 @@ LAST_UPDATED_TIME DATETIME, LAST_UPDATED_BY VARCHAR(50)); -- COMMENT 'TABLE TO STORE GENERATED NAMES'; -CREATE TABLE SERVICE_PARAMETER (SERVICE_PARAMETER_ID INTEGER PRIMARY KEY AUTO_INCREMENT(0,100), +CREATE TABLE SERVICE_PARAMETER (SERVICE_PARAMETER_ID INTEGER PRIMARY KEY AUTO_INCREMENT, NAME VARCHAR(500) NOT NULL COMMENT 'Parameter name', VALUE VARCHAR(500) COMMENT 'Parameter value', CREATED_TIME DATETIME DEFAULT CURRENT_TIMESTAMP, @@ -25,7 +25,7 @@ LAST_UPDATED_TIME DATETIME, LAST_UPDATED_BY VARCHAR(50) ); -CREATE TABLE IDENTIFIER_MAP (IDENTIFIER_MAP_ID INTEGER PRIMARY KEY AUTO_INCREMENT(0,100), +CREATE TABLE IDENTIFIER_MAP (IDENTIFIER_MAP_ID INTEGER PRIMARY KEY AUTO_INCREMENT, POLICY_FN_NAME VARCHAR(500) COMMENT 'Function name in policy manager' NOT NULL, JS_FN_NAME VARCHAR(500) COMMENT 'Equivalent name in Java or script', CREATED_TIME DATETIME DEFAULT CURRENT_TIMESTAMP, @@ -35,7 +35,7 @@ LAST_UPDATED_BY VARCHAR(50) ); -CREATE TABLE EXTERNAL_INTERFACE (EXTERNAL_INTERFACE_ID INTEGER PRIMARY KEY AUTO_INCREMENT(0,100), +CREATE TABLE EXTERNAL_INTERFACE (EXTERNAL_INTERFACE_ID INTEGER PRIMARY KEY AUTO_INCREMENT, SYSTEM VARCHAR(500) COMMENT 'Name of the external system', PARAM VARCHAR(500) COMMENT 'Parameters controlling the url', URL_SUFFIX VARCHAR(500) COMMENT 'The suffix of the URL for each value of the parameter', @@ -45,7 +45,7 @@ LAST_UPDATED_TIME DATETIME, LAST_UPDATED_BY VARCHAR(50) ); -CREATE TABLE POLICY_MAN_SIM (POLICY_ID INTEGER PRIMARY KEY AUTO_INCREMENT(0,100), +CREATE TABLE POLICY_MAN_SIM (POLICY_ID INTEGER PRIMARY KEY AUTO_INCREMENT, POLICY_NAME VARCHAR(500) COMMENT 'Policy name' NOT NULL, POLICY_RESPONSE VARCHAR(10000) COMMENT 'Policy value', CREATED_TIME DATETIME DEFAULT CURRENT_TIMESTAMP -- cgit 1.2.3-korg