Subject | Altering Primary Key on Table |
---|---|
Author | Tony Masefield |
Post date | 2005-09-01T04:45:20Z |
I need to change the sort order from ascending to descending on the
Primary Key for an (empty) table. Have tried (Alter Index/ Drop
Index) using IBExpert (Pers) and EMS Interbase both of which
generate SQL errors.
According to the IB 6 Lang Ref:
Alter Index
"Alter Index Fails if Index is defined for a UNIQUE, PRIMARY KEY or
FOREIGN KEY constraint .. to alter such an index, use DROP INDEX to
delete the index etc."
Drop Index
"Important- You cannot drop system-defined indexes, such as those
for UNIQUE, PRIMARY KEYS and FOREIGN KEYS".
So, how does one do this with an FB (1.5) Table? Must one drop the
table then re-create from scratch or is there an alternative 'work-
around'?
Regards,
Primary Key for an (empty) table. Have tried (Alter Index/ Drop
Index) using IBExpert (Pers) and EMS Interbase both of which
generate SQL errors.
According to the IB 6 Lang Ref:
Alter Index
"Alter Index Fails if Index is defined for a UNIQUE, PRIMARY KEY or
FOREIGN KEY constraint .. to alter such an index, use DROP INDEX to
delete the index etc."
Drop Index
"Important- You cannot drop system-defined indexes, such as those
for UNIQUE, PRIMARY KEYS and FOREIGN KEYS".
So, how does one do this with an FB (1.5) Table? Must one drop the
table then re-create from scratch or is there an alternative 'work-
around'?
Regards,