Deductive Database - Deductive Databases and Logic Programming

Deductive Databases and Logic Programming

Deductive databases reuse a large number of concepts from logic programming; rules and facts specified in the deductive database language Datalog look very similar to those in Prolog. However, there are a number of important differences between deductive databases and logic programming:

  • Order sensitivity and procedurality: In Prolog, program execution depends on the order of rules in the program and on the order of parts of rules; these properties are used by programmers to build efficient programs. In database languages (like SQL or Datalog), however, program execution is independent of the order of rules and facts.
  • Special predicates: In Prolog, programmers can directly influence the procedural evaluation of the program with special predicates such as the cut, this has no correspondence in deductive databases.
  • Function symbols: Logic Programming languages allow function symbols to build up complex symbols. This is not allowed in deductive databases.
  • Tuple-oriented processing: Deductive databases use set-oriented processing while logic programming languages concentrate on one tuple at a time.

Read more about this topic:  Deductive Database

Famous quotes containing the words logic and/or programming:

    Logic is not a body of doctrine, but a mirror-image of the world. Logic is transcendental.
    Ludwig Wittgenstein (1889–1951)

    If there is a price to pay for the privilege of spending the early years of child rearing in the driver’s seat, it is our reluctance, our inability, to tolerate being demoted to the backseat. Spurred by our success in programming our children during the preschool years, we may find it difficult to forgo in later states the level of control that once afforded us so much satisfaction.
    Melinda M. Marshall (20th century)