Retrieval of any item usually requires a single disk access. An sdbm database is kept in two files usually given the which indicate data pages in the .pag file. The application interface uses the datum structure to describe both keys and value s. A datum specifies a byte sequence of dsize size pointed to by dptr . Either of these will open or create the two necessary files.
Keys are unique within the database.
Functions that return an int will use -1 to indicate an error. The normal return value in that case is 0. Functions that return a datum will return nul- litem to indicate an error. The sum of the key and value data sizes where several keys hash to the same value must fit within one bitmap page. The contents of datum values returned are in volatile storage.