Synonyms

Definition

An important limitation of relational calculus/algebra is that it cannot express queries involving “paths” through an instance, such as taking the transitive closure over a binary relation. Datalog extends conjunctive queries with recursion to support such queries. A Datalog program consists of a set of rules, each of which is a conjunctive query. Recursion is introduced by allowing the same relational symbols in both the heads and the bodies of the rules. A surprising and elegant property of Datalog is that there are three very different but equivalent approaches to define its semantics, namely, the model-theoretic, proof-theoretic, and fixpoint approaches. Datalog inherits these properties from logic programming and its standard language Prolog. The main restriction that distinguishes Datalog from Prolog is that function symbols are not allowed.

Several techniques have been proposed for the efficient evaluation of Datalog programs. They are...