Subject Re: Modify Primary key
Author Alexander V.Nevsky
--- In firebird-support@yahoogroups.com, "skotaylor" <scott@d...>
wrote:
> > Alter Table T Add Constraint T_PK Primary Key (OldCol, NewCol);
> > Commit;
>
> What does T_PK stand for?

It is comfortable to give own names to constraints, to don't dig
system tables when you need information on them. Look at syntax of
Create Table and Alter Table.

> > Anyway, you should change them too. Perhaps you'll be forced to
> > reconnect several times due to "object in use" exception.
>
> hmmm... Like the error I got. I know it's not in use, currently,
but
> tried many times as you said; still no luck.

Usually you can change constraints being only one connected and if
you did'nt touched affected tables in previous statements in your
single connection. Getting this exception you should make sure there
is not another connections (from your computer too), re-connect your
single connection and perform problem statement first. BTW, it is
recommended to make any DDL statements being the only one connected,
some other reefs exists, not only "object in use".

Best regards, Alexander.