Disponibilité: Unix, Windows
The dbhash module provides a function to open databases using
the BSD This module provides an exception and a function:
The flag argument can be
The optional mode parameter is used to indicate the Unix permission bits that should be set if a new database must be
created; this will be masked by the current umask value for the
process.
See Also:db library. This module mirrors the interface of the
other Python database modules that provide access to DBM-style
databases. The bsddb module is required
to use dbhash.
error
open(path, flag[, mode])
db database and return the database object. The
path argument is the name of the database file.
'r' (the default), 'w',
'c' (which creates the database if it doesn't exist), or
'n' (which always creates a new empty database).
For platforms on which the BSD db library supports locking,
an "l" can be appended to indicate that locking should be
used.
dbm-style databases. db library.
Sous-sections