Berkeley DB Reference Guide: Access Methods
Полезная информация

Berkeley DB Reference Guide: Access Methods

Record delimiters (re_delim, DB_DELIMITER)

The Recno access method can be used to store both variable and fixed-length data items. By default, the data items are expected to be variable length.

When reading variable length records from a backing source file to store in the database, a delimiter character may be set as part of the db_open call to open the database, specifically by setting the re_delim element of the DB_INFO structure. Because there is no out-of-band value for this character, the DB_DELIMITER flag must also be set.

If an application is reading variable length records from a backing source file to store in the database and the DB_DELIMITER flag is not set, a newline character (i.e., 0x0a in the ASCII character set) is used as the delimiter.