Delphi Database, Delphi Components from ComponentAce
Products Download Order Contact us
Creating and Deleting Tables
Example
Previous  Top  Next



Creating tables

Use Absolute Database DBManager utility (...\AbsoluteDatabase\Ultils\Bin\DBManager.exe), if you would like to create table manually.

To create table from your application, you could perform the following steps:


1.Place TABSDatabase and TABSTable components from the "Absolute DB" page of the Component palette to a data module or on a form.  
2.Set up TABSDatabase component. Set the TABSDatabase.DatabaseName of the component to a unique value that will be used later to identify the database. Set the TABSDatabase.DatabaseFileName property to the name of the existing or new database file.  
3.Set up TABSTable component. Set the TABSTable.DatabaseName property from the drop-down list of available TABSDatabase components. Set the TABSTable.TableName property to the name of the table to create.  
4.Specify the Fields to Create. Set the TABSTable.FieldDefs property with the design-time editor or from the application code. More details...  
5.Specify the Indexes to Create (optional). Set the TABSTable.IndexDefs property with the design-time editor or from the application code. More details...  
6.Make sure that database file is created. Check TABSDatabase.Exists property and call to the TABSDatabase.CreateDatabase if the database file doesn't exist.  
7.Call TABSTable.CreateTable method.  
 
See also the Create Table Example and CREATE TABLE SQL command.  
 
 
Deleting tables

To delete table from the application code, use TABSTable.DeleteTable method.



        © 2003 - 2024 ComponentAce  | .net zip component | barcode for .net | delphi zip component | delphi database Dec 03, 2024