Skip to main content
Log in

A framework for comparing query languages in their ability to express boolean queries

  • Published:
Annals of Mathematics and Artificial Intelligence Aims and scope Submit manuscript

Abstract

For any query language \(\mathcal {F}\), we consider three natural families of boolean queries. Nonemptiness queries are expressed as e ≠ ∅ with e an \(\mathcal {F}\) expression. Emptiness queries are expressed as e = ∅. Containment queries are expressed as e1e2. We refer to syntactic constructions of boolean queries as modalities. In first order logic, the emptiness, nonemptiness and containment modalities have exactly the same expressive power. For other classes of queries, e.g., expressed in weaker query languages, the modalities may differ in expressiveness. We propose a framework for studying the expressive power of boolean query modalities. Along one dimension, one may work within a fixed query language and compare the three modalities. Here, we identify crucial query features that enable us to go from one modality to another. Furthermore, we identify semantical properties that reflect the lack of these query features to establish separations. Along a second dimension, one may fix a modality and compare different query languages. This second dimension is the one that has already received quite some attention in the literature, whereas in this paper we emphasize the first dimension. Combining both dimensions, it is interesting to compare the expressive power of a weak query language using a strong modality, against that of a seemingly stronger query language but perhaps using a weaker modality. We present some initial results within this theme. The two main query languages to which we apply our framework are the algebra of binary relations, and the language of conjunctive queries.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  1. Abiteboul, S., Hull, R., Vianu, V.: Foundations of databases. Addison-Wesley, Reading (1995)

  2. Ameloot, T., Ketsman, B., Neven, F., Zinn, D.: Weaker forms of monotonicity for declarative networking: A more fine-grained answer to the CALM-conjecture. ACM Trans. Database Syst. 40(4), 21 (2016)

    MathSciNet  Google Scholar 

  3. Angles, R., Barceló, P., Rios, G.: A practical query language for graph DBs. In: L. Bravo, M. Lenzerini (eds.) Proceedings 7th Alberto Mendelzon International Workshop on Foundations of Data Management, CEUR Workshop Proceedings, vol. 1087 (2013)

  4. Angles, R., Gutierrez, C.: Survey of graph database models. ACM Comput. Surv. 40(1), 1 (2008)

    Article  Google Scholar 

  5. Badia, A.: Quantifiers in action: Generalized quantification in query, Logical and Natural Languages, Advances in Database Systems, vol. 37 Springer (2009)

  6. Barceló, P.: Querying graph databases. In: Proceedings 32st ACM symposium on principles of databases, pp. 175–188. ACM (2013)

  7. Barwise, J., Cooper, R.: Generalized quantifiers and natural language. Linguistics and Philosophy 4(2), 159–219 (1981)

    Article  Google Scholar 

  8. Beeri, C., Vardi, M.: A proof procedure for data dependencies. J. ACM 31 (4), 718–741 (1984)

    Article  MathSciNet  Google Scholar 

  9. Van den Bussche, J.: Applications of Alfred Tarski’s ideas in database theory. In: Fribourg, L. (ed.) Computer science logic, lecture notes in computer science, vol. 2142. Springer (2001)

  10. ten Cate, B., Marx, M.: Navigational XPath: Calculus and algebra. SIGMOD Rec. 36(2), 19–26 (2007)

    Article  Google Scholar 

  11. Chandra, A., Merlin, P.: Optimal implementation of conjunctive queries in relational data bases. In: Proceedings 9th ACM symposium on the theory of computing, pp. 77–90. ACM (1977)

  12. Cruz, I., Mendelzon, A., Wood, P.: A graphical query language supporting recursion. In: Dayal, U., Traiger, I. (eds.) Proceedings of the ACM SIGMOD 1987 annual conference, SIGMOD record, vol. 16:3, pp 323–330. ACM Press (1987)

  13. Ebbinghaus, H. D., Flum, J.: Finite model theory, 2nd edn. Springer, Berlin (1999)

    MATH  Google Scholar 

  14. Fletcher, G., Gyssens, M., Leinders, D., Van den Bussche, J., Van Gucht, D., Vansummeren, S., Wu, Y.: Relative expressive power of navigational querying on graphs. In: Proceedings 14th international conference on database theory (2011)

  15. Fletcher, G., Gyssens, M., Leinders, D., Van den Bussche, J., Van Gucht, D., Vansummeren, S., Wu, Y.: The impact of transitive closure on the expressiveness of navigational query languages on unlabeled graphs. Ann. Math. Artif. Intell. 73(1–2), 167–203 (2015)

    Article  MathSciNet  Google Scholar 

  16. Fletcher, G., Gyssens, M., Leinders, D., Surinx, D., Van den Bussche, J., Van Gucht, D., Vansummeren, S., Wu, Y.: Relative expressive power of navigational querying on graphs. Inform. Sci. 298, 390–406 (2015)

    Article  MathSciNet  Google Scholar 

  17. Hell, P., Nesetril, J.: Graphs and homomorphisms. Oxford Lecture Series in Mathematics and Its Applications, OUP Oxford (2004). https://books.google.be/books?id=bJXWV-qK7kYC

    Book  Google Scholar 

  18. Hella, L., Luosto, K., Väänänen, J.: The hierarchy theorem for generalized quantifiers. The Journal of Symbolic Logic 61(3), 802–817 (1996)

    Article  MathSciNet  Google Scholar 

  19. Imielinski, T., Lipski, W.: The relational model of data and cylindric algebras. J. Comput. Syst. Sci. 28, 80–102 (1984)

    Article  MathSciNet  Google Scholar 

  20. Kolaitis, P.: On the expressive power of logics on finite models. In: Finite model theory and its applications, chap. 2. Springer (2007)

  21. Libkin, L.: Elements of finite model theory. Springer (2004)

  22. Libkin, L., Martens, W., Vrgoč, D.: Quering graph databases with XPath. In: Proceedings 16th international conference on database theory. ACM (2013)

  23. Marx, M., de Rijke, M.: Semantic characterizations of navigational XPath. SIGMOD Rec. 34(2), 41–46 (2005)

    Article  Google Scholar 

  24. Sagiv, Y., Yannakakis, M.: Equivalences among relational expressions with the union and difference operators. J. ACM 27(4), 633–655 (1980)

    Article  MathSciNet  Google Scholar 

  25. Surinx, D.: A framework for comparing query languages in their ability to express boolean queries. Ph.D. thesis, Hasselt University (2017). http://dsurinx.be/phd.pdf

    MATH  Google Scholar 

  26. Surinx, D., Van den Bussche, J.: A monotone preservation result for boolean queries expressed as a containment of conjunctive queries. arXiv:1808.08822 (2018)

  27. Surinx, D., Van den Bussche, J., Van Gucht, D.: The primitivity of operators in the algebra of binary relations under conjunctions of containments. In: Proceedings 32nd annual ACM/IEEE symposium on logic in computer science. IEEE Computer Society Press (2017)

  28. Surinx, D., Van den Bussche, J., Van Gucht, D.: A framework for comparing query languages in their ability to express boolean queries. In: Ferrarotti, F., Woltran, S. (eds.) Proceedings of the 10th international symposium on foundations of information and knowledge systems, Lecture notes in computer science, vol. 10833, pp 360–378. Springer (2018)

  29. Surinx, D., Fletcher, G., Gyssens, M., Leinders, D., Van den Bussche, J., Van Gucht, D., Vansummeren, S., Wu, Y.: Relative expressive power of navigational querying on graphs using transitive closure. Log. J. IGPL 23(5), 759–788 (2015)

    Article  MathSciNet  Google Scholar 

  30. Wood, P.: Query languages for graph databases. SIGMOD Rec. 41(1), 50–60 (2012)

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Dimitri Surinx.

Additional information

Publisher’s note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Surinx, D., Van den Bussche, J. & Van Gucht, D. A framework for comparing query languages in their ability to express boolean queries. Ann Math Artif Intell 87, 157–184 (2019). https://doi.org/10.1007/s10472-019-09639-5

Download citation

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10472-019-09639-5

Keywords

Mathematics Subject Classification (2010)

Navigation