|
@@ -77,8 +77,20 @@ CREATE INDEX IDX_UNIQUE_CODE_DATA_TIME ON ETA_API_QUOTA_DATA ("UNIQUE_CODE", "DA
|
|
|
CREATE INDEX ETA_API_DATA_UNIQUE_CODE_INDEX ON ETA_API_QUOTA_DATA ("UNIQUE_CODE")
|
|
|
|
|
|
|
|
|
+/*
|
|
|
+ * 辅助表,用于建立指标与指标分类之间的映射关系
|
|
|
+ */
|
|
|
+CREATE SEQUENCE SEQ_ETA_CLASSIFY_INDEX_MAPPING
|
|
|
+ START WITH 1
|
|
|
+ INCREMENT BY 1
|
|
|
+ NOMAXVALUE;
|
|
|
|
|
|
-
|
|
|
+CREATE OR REPLACE TRIGGER trg_SEQ_ETA_CLASSIFY_insert
|
|
|
+ BEFORE INSERT ON t_eta_CLASSIFY_INDEX_MAPPING
|
|
|
+ FOR EACH ROW
|
|
|
+BEGIN
|
|
|
+SELECT SEQ_ETA_CLASSIFY_INDEX_MAPPING.NEXTVAL INTO :new.id FROM dual;
|
|
|
+END;
|
|
|
|
|
|
|
|
|
|