Accuracer: The First And Only Cross-Platform BDE Replacement
Client-Server Single-File Embedded Database with SQL for Delphi / C++Builder / Kylix


RestructureTable Example
Top 


Accuracer1.Active := true;
with Accuracer1 do
begin
{modify fields structure}
with RestructureFieldDefs do
begin
// add new field
Add('Customer Name',ftString,300,False);
// rename 'id' field
Find('id').Name := 'Customer ID';
// set new length for Company field
Find('Company').Size := 100;
// delete 'Birthday' field
Delete(Find('Birthday').Index);
end;
{modify index definitions}
with RestructureIndexDefs do
begin
// add new index for Customer Name field
Add('CustomerName_Index','Customer Name',[ixCaseInsensitive]);
// rename primary index
Find('id_index').Fields := 'Customer ID';
Find('id_index').Name := 'CustomerID_index';
end;
{change fields structure}
RestructureTable;
end;



© AidAim Software Accuracer: Client-server Database Single-file Database Delphi Database Embedded Databas