Matricsoft - software development
products > Quickdb > database creation
description
database creation
table creation
record creation
record retrieval
record operations
file operations
database operations
definition operations
exceptions
relations
header file

Database creation

class db
{
    db(string const & name, int data_version=1);
    ~db();
}

db::db(string const & name, int data_version=1)

This is the constructor of the db class.

The name and the data_version parameters are used to set the name of the database (when wrote on disk) and the version of your informational model (of the data definitions), that is also written on disk.

db mydatabase("jobs");

db * mydatabase =new database("jobs");
delete mydatabase;

Result: the database is constructed and ready for use.

Note: the name and the data_version are just for reference (for the moment).

db::~db()

This is the destructor of the db class.
The object is destroyed, as well as all the data it contains (there shall be no memroy leak, because quickdb has been developed using resource management techniques, i.e. there is no nake pointer that can be left without being freed).