Firebird 2.5 丢弃约束错误
Firebird 2.5 drop constraint error
我在 WinXP 上使用 Firebird 2.5.4。
我有一个具有以下结构的 table:
CREATE TABLE "MY_TABLE_1"
(
"ID" "D_ID" NOT NULL,
...
"WHATEVER" VARCHAR(20) CHARACTER SET WIN1250 COLLATE PXW_HUN,
...
CONSTRAINT "C_MY_TABLE_1_U1" UNIQUE ("WHATEVER"),
PRIMARY KEY ("ID")
);
我想删除 "C_MY_TABLE_1_U1" 约束:
ALTER TABLE MY_TABLE_1 DROP CONSTRAINT C_MY_TABLE_1_U1;
然后我得到这个错误:
unsuccessful metadata update
ERASE RDB$RELATION_CONSTRAINTS failed
index unexpectedly deleted
At trigger 'RDB$TRIGGER_19'
At trigger 'RDB$TRIGGER_11'
我哪里失败了?
我添加了
CREATE DOMAIN "D_ID" BIGINT;
因为需要测试 ypur 脚本并且没有错误 (FB 2.5.4)。
您能否更具体地说明 OS/出现错误的 FB 版本?
CREATE DOMAIN "D_ID" BIGINT;
CREATE TABLE "MY_TABLE_1"
(
"ID" "D_ID" NOT NULL,
"WHATEVER" VARCHAR(20) CHARACTER SET WIN1250 COLLATE PXW_HUN,
CONSTRAINT "C_MY_TABLE_1_U1" UNIQUE ("WHATEVER"),
PRIMARY KEY ("ID")
);
ALTER TABLE MY_TABLE_1 DROP CONSTRAINT C_MY_TABLE_1_U1;
数据库已损坏,backup/restore 我可以删除约束。
我在 WinXP 上使用 Firebird 2.5.4。 我有一个具有以下结构的 table:
CREATE TABLE "MY_TABLE_1"
(
"ID" "D_ID" NOT NULL,
...
"WHATEVER" VARCHAR(20) CHARACTER SET WIN1250 COLLATE PXW_HUN,
...
CONSTRAINT "C_MY_TABLE_1_U1" UNIQUE ("WHATEVER"),
PRIMARY KEY ("ID")
);
我想删除 "C_MY_TABLE_1_U1" 约束:
ALTER TABLE MY_TABLE_1 DROP CONSTRAINT C_MY_TABLE_1_U1;
然后我得到这个错误:
unsuccessful metadata update
ERASE RDB$RELATION_CONSTRAINTS failed
index unexpectedly deleted
At trigger 'RDB$TRIGGER_19'
At trigger 'RDB$TRIGGER_11'
我哪里失败了?
我添加了
CREATE DOMAIN "D_ID" BIGINT;
因为需要测试 ypur 脚本并且没有错误 (FB 2.5.4)。
您能否更具体地说明 OS/出现错误的 FB 版本?
CREATE DOMAIN "D_ID" BIGINT;
CREATE TABLE "MY_TABLE_1"
(
"ID" "D_ID" NOT NULL,
"WHATEVER" VARCHAR(20) CHARACTER SET WIN1250 COLLATE PXW_HUN,
CONSTRAINT "C_MY_TABLE_1_U1" UNIQUE ("WHATEVER"),
PRIMARY KEY ("ID")
);
ALTER TABLE MY_TABLE_1 DROP CONSTRAINT C_MY_TABLE_1_U1;
数据库已损坏,backup/restore 我可以删除约束。