Database meta-schema (4dbx)

The 4dbx file is the database schema file for generated applications.

The 4dbx file contains the information about the tables, columns, and relations of the relational database that is needed by your application. It is used to create items in your Business Application diagram (4ba).

The 4dbx file handles CRUD operations for the generated application. For each table with a primary key in the database schema, the application generator creates its database CRUD operations (respectively INSERT, SELECT, UPDATE, and DELETE database statements).

You must have access set up for the database that the application will use.

Contraints management

The Application Generator creates functions to manage the database schema constraints. These constraints are checked during the CRUD operations for each table:
  • uniqueness check for its primary key (only if a primary key exists)
  • uniqueness check for each unique constraint (only if a primary key exists)
  • for one column, the not null constraint is checked
  • foreign key existence is checked

SERIAL management

You can define a primary key column as a SERIAL to use sequence numbers for the keys. BAM manages the SERIAL columns by using a single table named seqreg in the meta-schema (4dbx).