Defines

hamsterdb Data Access Mode Codes

Defines

#define HAM_DAM_RANDOM_WRITE   0x0001
#define HAM_DAM_SEQUENTIAL_INSERT   0x0002
#define HAM_DAM_ENFORCE_PRE110_FORMAT   0x8000

Detailed Description

which can be passed in the HAM_PARAM_DATA_ACCESS_MODE parameter when creating a new Database (see ham_create_ex) or opening an existing Database (see ham_open_ex).

Remarks:
The Data Access Mode describes the typical application behaviour (i.e. if data is only inserted sequentially) and allows hamsterdb to optimize its routines for this behaviour.
The Data Access Mode is not persisted in the Database. per Database basis. This means different Databases within the same Environment can have different Data Access Modes.
See also:
ham_create_ex
ham_open_ex
ham_hinting_flags

Define Documentation

#define HAM_DAM_ENFORCE_PRE110_FORMAT   0x8000

Definition at line 218 of file hamsterdb.h.

#define HAM_DAM_RANDOM_WRITE   0x0001

Assume random access (a mixed bag of random insert and delete).

This is the default setting for (non-RECNO) Databases created with versions newer than 1.0.9.

Note: RECNO-based Databases will start in the implicit HAM_DAM_SEQUENTIAL_INSERT mode instead.

This flag is non persistent.

Definition at line 205 of file hamsterdb.h.

#define HAM_DAM_SEQUENTIAL_INSERT   0x0002

Assume sequential insert (and few or no delete) operations.

This is the default setting for RECNO based Databases created with versions newer than 1.0.9.

This flag is non persistent.

Definition at line 215 of file hamsterdb.h.