Runtime adding files to database via a TADOConnection - how?



Howdy!

If I have connected to an Access database on disk, via a TADOConnection component, then how do I add fields at runtime? I find no method that would enable me to do it. Adding via SQL - is that it? (This is no SQL group, but any hints?)

Also, if a TADODataset contains the field I want to add, but the base on disk doesn't, how do best I read the characteristics (type and so on) of the field from the Dataset and add it to the base on disk? Again, this must all be at runtime!

Identifying the fields missing on disk and finding the name of it from the Dataset is under control. What I now need help with is "only" identifying the datatype of the field and how to add it to the database on disk.

/Pontus

Setup: Delphi 2006, Windows
.



Relevant Pages