Subject | Rename FOREIGN KEY column |
---|---|
Author | vojtech.vild |
Post date | 2007-08-15T18:26:32Z |
Hi all,
is in the Firebird an easy way how to rename FOREIGN KEY column?
(or the PRIMARY KEY column)
Example:
CREATE TABLE test (id integer PRIMARY KEY);
CREATE TABLE test2 (id integer PRIMARY KEY, ref integer REFERENCES test);
ALTER TABLE test2 ALTER ref TO reftest;
Error:
unsuccessful metadata update
MODIFY RDB$RELATION_FIELDS failed
action cancelled by trigger (1) to preserve data integrity
Cannot update index segment used by an Integrity Constraint
Regards,
Wild
is in the Firebird an easy way how to rename FOREIGN KEY column?
(or the PRIMARY KEY column)
Example:
CREATE TABLE test (id integer PRIMARY KEY);
CREATE TABLE test2 (id integer PRIMARY KEY, ref integer REFERENCES test);
ALTER TABLE test2 ALTER ref TO reftest;
Error:
unsuccessful metadata update
MODIFY RDB$RELATION_FIELDS failed
action cancelled by trigger (1) to preserve data integrity
Cannot update index segment used by an Integrity Constraint
Regards,
Wild