Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version


Firebird embedded is still undergoing modifications to have it working fully in an easy manner. Until then some of the functions need to be worked around but with these alternatives, Firebird does work very well.

For your situation there are two items. Based upon a comment here -> How to change the order of columns in table ?, you need to do this from the main Base menu item 'Tools->SQL...' and also use this statement:

alter table "table1" add constraint PK_MY_TABLE primary key (ID)

Once completed, save the Base file (with Firebird embedded changes are not committed until the Base file is saved), then close all LO files & re-open the Base file. You should now find the table has the selected field set as primary key.

There are also other methods. One is to delete the old field & enter a new one & set as primary key. Another is to copy/paste the table and when pasting set the appropriate field as a primary key.