Towards a Constraint Deductive Database Language based on Hereditary Harrop Formulas
Susana Nieva, Jaime Sánchez-Hernández
Abstract
Susana Nieva, Jaime Sánchez-Hernández
Abstract
In the same way that Datalog and Datalog with constraints arise when modelling databases inspired on Prolog and CLP (Constraint Logic Programming), respectively, we introduce the constraint logic programming scheme HH(C) (Hereditary Harrop formulas with Constraints) as the basis for a database language. We show that HH(C) can fulfill all relational algebra operations but set difference, so that it has to be extended with a limited form of negation. Since the underlying logic of our system is an extension of Horn clauses, we will show that the resulting database language is more powerful than both relational algebra and calculus. For instance, it is possible to define recursive views. In addition, the use of constraints permits of modelling infinite databases, as in Datalog with constraints. Moreover, our approach improves the expressivity of recursive Datalog with negation because, for instance, hypothetical queries are allowed.
OpenAlex reports 3 citations for this work. Citation counts describe recorded attention and do not establish research quality.
A contribution statement is not available in the OpenAlex record.
Method details are not available in the OpenAlex metadata.
Findings are not separately available in the OpenAlex metadata.
Limitations are not available in the OpenAlex metadata.
Application details are not available in the OpenAlex metadata.
In the same way that Datalog and Datalog with constraints arise when modelling databases inspired on Prolog and CLP (Constraint Logic Programming), respectively, we introduce the constraint logic programming scheme HH(C) (Hereditary Harrop formulas with Constraints) as the basis for a database language. We show that HH(C) can fulfill all relational algebra operations but set difference, so that it has to be extended with a limited form of negation. Since the underlying logic of our system is an extension of Horn clauses, we will show that the resulting database language is more powerful than both relational algebra and calculus. For instance, it is possible to define recursive views. In addition, the use of constraints permits of modelling infinite databases, as in Datalog with constraints. Moreover, our approach improves the expressivity of recursive Datalog with negation because, for instance, hypothetical queries are allowed.
Key concepts: Datalog, Logic programming, Programming language, Prolog, Deductive database, Negation, Relational database, Computer science