|
|
@ -3,7 +3,8 @@ CREATE TABLE DM_DEVICE_TYPE (
|
|
|
|
NAME VARCHAR(300) DEFAULT NULL,
|
|
|
|
NAME VARCHAR(300) DEFAULT NULL,
|
|
|
|
PROVIDER_TENANT_ID INTEGER NULL,
|
|
|
|
PROVIDER_TENANT_ID INTEGER NULL,
|
|
|
|
SHARED_WITH_ALL_TENANTS BIT NOT NULL DEFAULT 0,
|
|
|
|
SHARED_WITH_ALL_TENANTS BIT NOT NULL DEFAULT 0,
|
|
|
|
PRIMARY KEY (ID)
|
|
|
|
PRIMARY KEY (ID),
|
|
|
|
|
|
|
|
CONSTRAINT DEVICE_TYPE_NAME UNIQUE(NAME)
|
|
|
|
);
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
|
|
CREATE INDEX IDX_DEVICE_TYPE ON DM_DEVICE_TYPE (NAME);
|
|
|
|
CREATE INDEX IDX_DEVICE_TYPE ON DM_DEVICE_TYPE (NAME);
|
|
|
@ -122,12 +123,12 @@ CREATE TABLE DM_PROFILE (
|
|
|
|
ID INTEGER IDENTITY(1,1) NOT NULL,
|
|
|
|
ID INTEGER IDENTITY(1,1) NOT NULL,
|
|
|
|
PROFILE_NAME VARCHAR(45) NOT NULL ,
|
|
|
|
PROFILE_NAME VARCHAR(45) NOT NULL ,
|
|
|
|
TENANT_ID INTEGER NOT NULL ,
|
|
|
|
TENANT_ID INTEGER NOT NULL ,
|
|
|
|
DEVICE_TYPE_ID INTEGER NOT NULL ,
|
|
|
|
DEVICE_TYPE VARCHAR(300) NOT NULL ,
|
|
|
|
CREATED_TIME DATETIME NOT NULL ,
|
|
|
|
CREATED_TIME DATETIME NOT NULL ,
|
|
|
|
UPDATED_TIME DATETIME NOT NULL ,
|
|
|
|
UPDATED_TIME DATETIME NOT NULL ,
|
|
|
|
PRIMARY KEY (ID) ,
|
|
|
|
PRIMARY KEY (ID) ,
|
|
|
|
CONSTRAINT DM_PROFILE_DEVICE_TYPE FOREIGN KEY (DEVICE_TYPE_ID) REFERENCES
|
|
|
|
CONSTRAINT DM_PROFILE_DEVICE_TYPE FOREIGN KEY (DEVICE_TYPE) REFERENCES
|
|
|
|
DM_DEVICE_TYPE (ID) ON DELETE NO ACTION ON UPDATE NO ACTION
|
|
|
|
DM_DEVICE_TYPE (NAME) ON DELETE NO ACTION ON UPDATE NO ACTION
|
|
|
|
);
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE DM_POLICY (
|
|
|
|
CREATE TABLE DM_POLICY (
|
|
|
|