# The complexity of relational query languages (Extended Abstract)

@inproceedings{Vardi1982TheCO, title={The complexity of relational query languages (Extended Abstract)}, author={Moshe Y. Vardi}, booktitle={Symposium on the Theory of Computing}, year={1982} }

Two complexity measures for query languages are proposed. Data complexity is the complexity of evaluating a query in the language as a function of the size of the database, and expression complexity is the complexity of evaluating a query in the language as a function of the size of the expression defining the query. We study the data and expression complexity of logical languages - relational calculus and its extensions by transitive closure, fixpoint and second order existential…

## 1,503 Citations

### On the complexity of database queries (extended abstract)

- Computer SciencePODS '97
- 1997

It is shown that, if the query size (or the number of variables in the query) is considered as a parameter, then the relational calculus and its fragments are classified at appropriate levels of the so-called W hierarchy of Downey and Fellows.

### Tractable query languages for complex object databases

- Computer SciencePODS '91
- 1991

The expressiveness and complexity of several calculus-based query languages for complex objects are considered and an extension of the fixpoint queries to complex objects is shown to express precisely the PTIME queries, under the assumption that the database makes full use of all its types.

### On the complexity of bounded-variable queries (extended abstract)

- Computer SciencePODS '95
- 1995

This paper shows that, for bounded-variable queries, the gap between their expression and combined complexities, one one hand, and their data complexity, on the other hand, narrows and in some cases disappears, and suggests variable minimization as a query optimization methodology.

### Complexity of higher-order queries

- Computer ScienceICDT '11
- 2011

This work gives a full picture of the complexity of evaluation for λ-embedded query languages, looking at a number of variations: with negation and without; with only relational algebra operators, and also with a recursion mechanism in the form of a query iteration operator.

### Database query languages embedded in the typed lambda calculus

- Computer Science[1993] Proceedings Eighth Annual IEEE Symposium on Logic in Computer Science
- 1993

It is shown how to naturally embed, in the typed lambda -calculus with equality, many database query languages, including the relational calculus/algebra, inflationary Datalog, and the complex object…

### Expressive power and data complexity of nonrecursive query languages for lists and trees (extended abstract)

- Computer SciencePODS '00
- 2000

This work extends the traditional query languages by primitives for handling lists and trees and proves that these query languages have polynomial data complexity under any “reasonable” encoding of inputs.

### On the complexity of nonrecursive XQuery and functional query languages on complex values

- Computer Science, MathematicsPODS '05
- 2005

It is shown that Core XQuery is just as hard as monad algebra w.r.t. combined complexity, and that it is in TC0 if the query is assumed fixed.

### The expressiveness of a family of finite set languages

- Computer SciencePODS '91
- 1991

The role of ordering in database query languages is discussed and it is shown that the hom operator of the Machiavelli language in [OBB] does not capture all the order-independent polynomial-time properties.

## References

SHOWING 1-10 OF 23 REFERENCES

### On the expressive power of query languages for relational databases

- Computer SciencePOPL '82
- 1982

This work provides a definition of relational query languages and their expressive power, and analyzes the expressive power of several real query languages, including languages based on the relational calculus, languages with set operators and aggregate functions, and procedural query languages.

### Structure and complexity of relational queries

- Computer Science21st Annual Symposium on Foundations of Computer Science (sfcs 1980)
- 1980

### Programming primitives for database languages

- Computer SciencePOPL '81
- 1981

This paper examines a number of programming primitives in query languages for relational databases and shows that equality cannot be simulated using all the other primitives, generic variables can be simulated with only ranked variables, and that with bounded loops one can determine the isomorphism class of the database when generic variables are allowed, but not otherwise.

### Universality of data retrieval languages

- Computer SciencePOPL
- 1979

Although relational algebra and relational calculus satisfy these principles, there are certain queries involving least fixed points that cannot be expressed by these languages, yet that also satisfy the principles.

### Optimal implementation of conjunctive queries in relational data bases

- Computer ScienceSTOC '77
- 1977

It is shown that while answering conjunctive queries is NP complete (general queries are PSPACE complete), one can find an implementation that is within a constant of optimal.

### Horn clauses and the fixpoint query hierarchy

- Computer SciencePODS
- 1982

It is shown that logic programs express precisely the queries in YE+ (the set of queries representable by a fixpoint applied to a positive existential query), which equals FP, the set of first order queries closed under fixpoints.

### On the Completeness of Query Languages for Relational Data Bases

- Computer ScienceMFCS
- 1978

A query language was proved to be complete and this results gives strong theoretical basis to Codd's definition of completeness.

### Generalized first-order spectra, and polynomial. time recognizable sets

- Mathematics
- 1974

The spectrum of a first-order sentence σ is the set of cardinalities of its finite models. Jones and Selman showed that a set C of numbers (written in binary) is a spectrum if and only if C is in the…