Hi,
I have an application that needs to create some tables when it's launched. It first deletes the tables if they exist then recreate them. The problem is that one field (called 'sc') gets translated into 's_' when the table actually gets created in the db.
--------------------------
"two wrongs don't make a right, but three lefts do" - the unknown sage
I have an application that needs to create some tables when it's launched. It first deletes the tables if they exist then recreate them. The problem is that one field (called 'sc') gets translated into 's_' when the table actually gets created in the db.
Code:
with form1.Table1 do begin
Active := False;
TableName := 'Angajatori';
with FieldDefs do begin
Clear;
with AddFieldDef do begin Name := 'nr_crt';DataType := ftInteger;Required := True; end;
.....................................
with AddFieldDef do begin Name := '[b]sc[/b]';DataType := ftString; size := 10; end;
.....................................
end;
with IndexDefs do begin
Clear;
with AddIndexDef do begin Name := 'nrcrt';Fields := 'nr_crt';Options := [ixPrimary];end;
end;
CreateTable;
end;
--------------------------
"two wrongs don't make a right, but three lefts do" - the unknown sage