createdbtbl() - Create a table, and add it to the data dictionary.


DBTBL *createdbtbl
    DDIC *ddic,
    DD *dd,
    char *tn,
    char *lname,
    char *comment,
    int type


DDIC *ddic

Data dictionary to use.
DD *dd

Data definition for table.
char *tn

File name for the table.
char *lname

Logical table name.
char *comment

A description of the table.
int type

Table type.

This updates the tables in the data dictionary to show the addition of this table. The structure of the table is contained in dd, the data definition. A table is created, and a pointer to the table returned.

The type of the table can be either 'T' for a regular table or 'B' for a BTREE table. BTREE tables provide fast access from the primary key, although no further indices are allowed. A BTREE table has little significance within the loader functions, although the gains occur when the table is accessed from SQL, where the query plan generator can use the inherent index.

opendbtbl(), closedbtbl(), createindex()

Copyright © Thunderstone Software     Last updated: May 19 2023
Copyright © 2023 Thunderstone Software LLC. All rights reserved.