FairCom Corporation


4.3.10 ctdbAllocDatabase


Allocate and initiate a new database handle.

Declaration

CTHANDLE ctdbAllocDatabase(CTHANDLE Handle)

Description

ctdbAllocDatabase allocates memory and initialize a new database handle. Before any operation on a database can take place, the application must allocate a database handle.

The database handle is released by calling ctdbFreeDatabase. Do not release the database handle by calling the C runtime library function free.

Returns

ctdbAllocDatabase returns the database handle on success or NULL on failure.

Example

CTHANDLE hDatabase = ctdbAllocDatabase(hSession);

See also

ctdbFreeDatabase, ctdbAllocSession, ctdbAllocTable


FairCom Corporation
www.faircom.com