June 2001
Intermediate to advanced
688 pages
19h 18m
English
#include <db.h> int db_create(DB **dbp, DB_ENV *dbenv, u_int32_t flags);
The db_create function creates a DB structure that is the handle for a Berkeley DB database. A pointer to this structure is returned in the memory referenced by db.
If the dbenv argument is NULL, the database is standalone; that is, it is not part of any Berkeley DB environment.
If the dbenv argument is not NULL, the database is created within the specified Berkeley DB environment. The database access methods automatically make calls to the other subsystems in Berkeley DB, based on the enclosing environment. For example, if the environment has been configured to use locking, the access methods will automatically acquire the correct locks when reading ...