Subject | Re: [firebird-support] Drop a field with PK with FB 2.1 |
---|---|
Author | Thomas Steinmaurer |
Post date | 2008-04-08T10:46Z |
>> It's not possible with FB 2.1 RC2. When I'm trying to drop a field whichWhich has been marked as bug and got fixed in FB 2.1. The whole story is
>> is part of a composite PK constraint, I get the following error message:
>>
>> unsuccessful metadata update ERASE RDB$RELATION_FIELDS failed action
>> cancelled by trigger (1) to preserve data integrity Cannot delete column
>> being used in an Integrity Constraint.
>
> I run FB 2.1 RC2 and it is possible to run the following script
>
> CREATE TABLE CUSTOMERGROUPS (
> CUID INTEGER NOT NULL);
> alter table CUSTOMERGROUPS
> add constraint PK_CUSTOMERGROUPS
> primary key (CUID);
> COMMENT ON COLUMN CUSTOMERGROUPS.CUID IS
> 'Primary Key';
>
> commit;
>
> ALTER TABLE CUSTOMERGROUPS
> ADD CUPARENTID INTEGER;
>
> commit;
>
> ALTER TABLE CUSTOMERGROUPS DROP CUID;
>
> commit;
>
>
> With FB 2.0.3 I get the error mentioned in my last mail.
here: http://tracker.firebirdsql.org/browse/CORE-878
--
Best Regards,
Thomas Steinmaurer
LogManager Series - Logging/Auditing Suites supporting
InterBase, Firebird, Advantage Database, MS SQL Server and
NexusDB V2
Upscene Productions
http://www.upscene.com