

-------------------------------------------------------------------------------
--  dict schema
-------------------------------------------------------------------------------
CREATE TABLE DICT_SCHEMA(
        ID BIGINT NOT NULL,
        NAME VARCHAR(200),
	TYPE VARCHAR(50),
	PRIORITY INT,
	DESCN VARCHAR(200),
	TYPE_ID BIGINT,
        CONSTRAINT PK_DICT_SCHEMA PRIMARY KEY(ID),
	CONSTRAINT FK_DICT_SCHEMA_TYPE FOREIGN KEY(TYPE_ID) REFERENCES DICT_TYPE(ID)
);

COMMENT ON TABLE DICT_SCHEMA IS '数据字典';
COMMENT ON COLUMN DICT_SCHEMA.ID IS '唯一主键';
COMMENT ON COLUMN DICT_SCHEMA.NAME IS '名称';
COMMENT ON COLUMN DICT_SCHEMA.TYPE IS '类型';
COMMENT ON COLUMN DICT_SCHEMA.PRIORITY IS '排序';
COMMENT ON COLUMN DICT_SCHEMA.DESCN IS '描述';
COMMENT ON COLUMN DICT_SCHEMA.TYPE_ID IS '外键，DICT_TYPE';


