Adds a new TFieldDef object with the name determined by Name.
procedure AddField(const Name: string; FieldType: TFieldType; Size: integer = 0; Required: boolean = False);
Call the AddField method to add a new TFieldDef object with the name determined by Name. FieldType can be ftString, ftWideString, ftSmallint, ftInteger, ftAutoInc, ftWord, ftBoolean, ftLargeint, ftFloat, ftCurrency, ftDate, ftTime, ftDateTime, ftBlob, or ftMemo. When you add ftString or ftWideString field you should specify Size of the string. When the ftAutoInc field type is set, a field of the special TVirtualAutoIncField type will be created in the virtual table, which can generate auto-increment field values.
VirtualTable1.AddField('CODE', ftInteger, 0); VirtualTable1.AddField('NAME', ftString, 30);