操作系统:银河麒麟 V10 SP3 ARM64
数据库:达梦8
活字格设计器和服务器版本:均为 10.0.102.0
问题描述:
如上图所示,这段相同的代码,在生产和测试环境表现不一样,请问是数据库问题,还是其它原因导致的?请教解决思路,谢谢!
- CREATE TABLE "SALARY"."月度工资表" ( "ID" BIGINT AUTO_INCREMENT NOT NULL, "公司" BIGINT, "员工姓名" VARCHAR2(500), "工资月份" DATETIME(6), "工资分类" VARCHAR2(500), "序号" BIGINT, "公司CODE" VARCHAR2(500), "员工ID" VARCHAR2(500), "手机号码" VARCHAR2(500), "FGC_Creator" VARCHAR2(500), "FGC_CreateDate" DATETIME(6), "FGC_LastModifier" VARCHAR2(500), "FGC_LastModifyDate" DATETIME(6), "FGC_UpdateHelp" VARCHAR2(40), "整数" BIGINT, NOT CLUSTER PRIMARY KEY("ID") USING INDEX TABLESPACE "HZG_INDEX" ) STORAGE(ON "HRGZT_DATA", CLUSTERBTR) AUTO_INCREMENT = 5; CREATE OR REPLACE INDEX "IFgcAutoIX2736faf3d8c74630be4d" ON "SALARY"."月度工资表"("FGC_UpdateHelp" ASC) STORAGE(ON "HZG_INDEX", CLUSTERBTR) ; CREATE OR REPLACE UNIQUE INDEX "IDX_SA_GZ_ID" ON "SALARY"."月度工资表"("ID" ASC) STORAGE(ON "HZG_INDEX", CLUSTERBTR) ; CREATE OR REPLACE UNIQUE INDEX "月度工资表_员工姓名_IDX" ON "SALARY"."月度工资表"("员工姓名" ASC,"工资月份" ASC,"工资分类" ASC,"手机号码" ASC) STORAGE(ON "HZG_INDEX", CLUSTERBTR) ;
复制代码
完整的建库SQL如下:
- select * from "SALARY"."工资数据表";
- select * from "SALARY"."月度工资表";
- drop TABLE "SALARY"."工资数据表";
- DROP TABLE "SALARY"."月度工资表";
- -- SALARY.月度工资表 definition
- CREATE TABLE SALARY.月度工资表 (
- ID BIGINT NOT NULL AUTO_INCREMENT,
- 公司 BIGINT NULL,
- 员工姓名 VARCHAR2(500) NULL,
- 工资月份 DATETIME NULL,
- 工资分类 VARCHAR2(500) NULL,
- 序号 BIGINT NULL,
- 公司CODE VARCHAR2(500) NULL,
- 员工ID VARCHAR2(500) NULL,
- 手机号码 VARCHAR2(500) NULL,
- "FGC_Creator" VARCHAR2(500) NULL,
- "FGC_CreateDate" DATETIME NULL,
- "FGC_LastModifier" VARCHAR2(500) NULL,
- "FGC_LastModifyDate" DATETIME NULL,
- "FGC_UpdateHelp" VARCHAR2(40) NULL,
- CONSTRAINT CONS_MS_ID PRIMARY KEY (ID)
- );
- CREATE INDEX "IFgcAutoIX2736faf3d8c74630be4d" ON SALARY.月度工资表 ("FGC_UpdateHelp");
- CREATE UNIQUE INDEX UIDX_MS_ID ON SALARY.月度工资表 (ID);
- CREATE UNIQUE INDEX 月度工资表_员工姓名_IDX ON SALARY.月度工资表 (员工姓名,工资月份,工资分类,手机号码);
- -- SALARY.工资数据表 definition
- CREATE TABLE SALARY.工资数据表 (
- ID BIGINT NOT NULL AUTO_INCREMENT,
- 月度工资ID BIGINT NULL,
- 序号 BIGINT NULL,
- 工资项名称 VARCHAR2(500) NULL,
- 值 VARCHAR2(500) NULL,
- "FGC_Creator" VARCHAR2(500) NULL,
- "FGC_CreateDate" DATETIME NULL,
- "FGC_LastModifier" VARCHAR2(500) NULL,
- "FGC_LastModifyDate" DATETIME NULL,
- "FGC_UpdateHelp" VARCHAR2(40) NULL,
- CONSTRAINT CONS_MS_ITEM_ID PRIMARY KEY (ID),
- CONSTRAINT 工资数据表_月度工资表_FK FOREIGN KEY (月度工资ID) REFERENCES SALARY.月度工资表(ID) ON DELETE CASCADE
- );
- CREATE INDEX "IFgcAutoIXab55f9bc45244f6d997a" ON SALARY.工资数据表 ("FGC_UpdateHelp");
- CREATE UNIQUE INDEX UIDX_MS_ITEM_ID ON SALARY.工资数据表 (ID);
- CREATE INDEX IDX_SI_MS_ID ON SALARY.工资数据表 (月度工资ID);
复制代码
|