Next: , Previous: , Up: Top   [Contents][Index]


5 Number of Records

gdbm interface: int gdbm_count (GDBM_FILE dbf, gdbm_count_t *pcount)

Counts the number of records in the database dbf. On success, stores it in the memory location pointed to by pcount and returns 0. On error, sets gdbm_errno (if relevant, also errno) and returns -1.

gdbm interface: int gdbm_bucket_count (GDBM_FILE dbf, size_t *pcount)

Counts the number of buckets in the database dbf. On success, stores it in the memory location pointed to by pcount and return 0. On error, sets gdbm_errno (if relevant, also errno) and returns -1.