-------------------------------------------------------- -- DDL for Table CFG_LOC -------------------------------------------------------- CREATE TABLE "MIRLE"."CFG_LOC" ( "STORAGE_ID" VARCHAR2(7 CHAR), "LOC_ID" VARCHAR2(9 CHAR), "PRODUCT_TYPE" VARCHAR2(10 CHAR), "ROW_X" VARCHAR2(3 CHAR), "BAY_Y" VARCHAR2(3 CHAR), "LEVEL_Z" VARCHAR2(3 CHAR), "LOC_SIZE" VARCHAR2(1 CHAR) DEFAULT 'G', "LOC_WEIGHT" NUMBER(5,0), "LOC_HEIGHT" NUMBER(5,0), "LOC_DEPTH" NUMBER(5,0), "LOC_LOADING" NUMBER(6,0), "REMARKS" VARCHAR2(255 CHAR), "AXIS_X" NUMBER(6,2) DEFAULT 0.0, "AXIS_Y" NUMBER(6,2) DEFAULT 0.0, "CREATE_USER" VARCHAR2(30 CHAR), "CREATE_TIME" TIMESTAMP (6) DEFAULT systimestamp, "UPDATE_USER" VARCHAR2(30 CHAR), "UPDATE_TIME" TIMESTAMP (6) DEFAULT systimestamp, "STATUS" NUMBER(1,0) DEFAULT 0, ) SEGMENT CREATION IMMEDIATE PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) TABLESPACE "SYSTEM" ; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."STORAGE_ID" IS '儲存區編號'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."LOC_ID" IS '儲位編號'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."PRODUCT_TYPE" IS '存放的產品類別'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."ROW_X" IS '列'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."BAY_Y" IS '行'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."LEVEL_Z" IS '層'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."LOC_SIZE" IS '儲位尺寸'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."LOC_WEIGHT" IS '儲位寬度(m)'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."LOC_HEIGHT" IS '儲位高度(m)'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."LOC_DEPTH" IS '儲位深度(m)'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."LOC_LOADING" IS '儲位可乘載重量(kg)'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."REMARKS" IS '備註'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."AXIS_X" IS '圖座標 X'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."AXIS_Y" IS '圖座標 Y'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."CREATE_USER" IS '建立人員'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."CREATE_TIME" IS '建立時間'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."UPDATE_USER" IS '更新人員'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."UPDATE_TIME" IS '更新時間'; COMMENT ON COLUMN "MIRLE"."CFG_LOC"."STATUS" IS '資料狀態'; -------------------------------------------------------- -- DDL for Index CFG_LOC_PK -------------------------------------------------------- CREATE UNIQUE INDEX "MIRLE"."CFG_LOC_PK" ON "MIRLE"."CFG_LOC" ("STORAGE_ID", "LOC_ID") PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) TABLESPACE "SYSTEM" ; -------------------------------------------------------- -- Constraints for Table CFG_LOC -------------------------------------------------------- ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("STORAGE_ID" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("LOC_ID" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("PRODUCT_TYPE" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("ROW_X" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("BAY_Y" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("LEVEL_Z" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("CREATE_USER" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("CREATE_TIME" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("UPDATE_USER" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("UPDATE_TIME" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" MODIFY ("STATUS" NOT NULL ENABLE); ALTER TABLE "MIRLE"."CFG_LOC" ADD CONSTRAINT "CFG_LOC_PK" PRIMARY KEY ("STORAGE_ID", "LOC_ID") USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) TABLESPACE "SYSTEM" ENABLE;