10.26.1 Basics
The idea is to get a behavior similar to assert/1
,
retract/1
and clause/2
, but the terms are stored on
file instead of in primary memory. Like the Prolog database,
LMDB will store variables with attributes or with blocked
goals as ordinary variables.
The differences compared with the Prolog database are:
-
A database must be explicitly created, and occupies a file system directory.
A database must be opened before any access and closed after the
last access.
- The functors and the indexing specifications of the terms to
be stored have to be given when the database is
created. It is possible to index on other parts of the term than just the
functor and first argument. (see LMDB DB-Spec Details).
- Changes are not guaranteed to affect the database until it is explicitly synced.
Send feedback on this subject.