Fix bug #160 : interface allows selecting autoinc without index or key. Not the neatest solution as the PK checkbox could be unchecked again if AI is unchecked but that didn't seem worth the hacks that would need. The table creation dialog should be reinvented some day.

This commit is contained in:
Ansgar Becker
2008-09-25 23:06:34 +00:00
parent 609fcedcb2
commit ff2a5522e7

View File

@ -450,6 +450,8 @@ procedure TCreateTableForm.CheckBoxAutoincrementClick(Sender: TObject);
begin
// AutoIncrement
cols[index].AutoIncrement := CheckBoxAutoIncrement.Checked;
// Fix bug #160 - auto increment is only valid for PK columns
CheckboxPrimary.Checked := True;
end;
procedure TCreateTableForm.Button1Click(Sender: TObject);