4D v13.4Creating and modifying tables |
||
|
4D v13.4
Creating and modifying tables
Creating and modifying tables
You can create tables at any time. 4D names the first table [Table_1] and then names additional tables sequentially, up to [Table_32767]. You can rename the tables to suit your purposes. You can remove obsolete tables or tables created by mistake. This deletion can be permanent or not. Be careful, if the deletion is permanent, any data stored in the table are also deleted. You can also remove a table from the editors of the Application mode by making it invisible. You can set triggers and attributes for each table as needed. These properties are described in Table properties. You can create a new table either directly in the Structure window, or via a dialog box. Direct creation is faster; but creation using the dialog box lets you specify certain parameters of the table and cancel the operation when necessary. You can also create tables using copy-paste. To create a new table directly:
Note: If you want to put the table in a specific folder, you will need to use the Home Page of the Explorer. To create a new table using the “New table” dialog box:
To create a new table by copy-paste:
You can rename tables at any time. If you have used the old table name in a method, 4th Dimension automatically changes it to the new name provided the method is closed. If the method is open, you must make the changes yourself. Each table name must be unique in the database. You can rename a table directly in the Structure editor, in the Explorer, or using the Inspector palette. To rename a table directly (Structure editor or Tables page of the Explorer):
To rename a table using the Inspector palette of the Structure editor:
Note: To find out the rules for naming tables, refer to Rules for naming tables and fields. You can delete tables from your database. There are two ways of deleting tables in 4D: permanent deletion (the table and its data are actually removed from the database) and non-permanent deletion (the table is simply put into the Trash (see the Trash Page) and may be recovered subsequently). To permanently delete one or more database tables from the Structure editor:
If you click OK, 4D will carry out the following operations:
Non-permanent deletion of a table consists in putting it in the Trash of the database (which can be accessed via the Explorer), just like the file deletion mechanisms implemented by Windows and Mac OS. The table then no longer appears in the 4D editors and its contents become inaccessible but it can still be recovered so long as the Trash is not emptied. To put one or more tables into the Trash from the Structure editor:
When a table is deleted, the other tables of the database are not renumbered, so as to avoid endangering the stability of the database. It is therefore possible, for example, to have a database with three tables numbered 2, 4 and 5. Note that the numbers of permanently deleted tables are reused when new tables are created subsequently. |
PROPERTIES
Product: 4D TAGS Supprimer table, Créer table, Numéro table*** |