Evaluating and Benchmarking SPARQL Query Containment Solvers

  • Melisachew Wudage Chekol
  • Jérôme Euzenat
  • Pierre Genevès
  • Nabil Layaïda
Part of the Lecture Notes in Computer Science book series (LNCS, volume 8219)


Query containment is the problem of deciding if the answers to a query are included in those of another query for any queried database. This problem is very important for query optimization purposes. In the SPARQL context, it can be equally useful. This problem has recently been investigated theoretically and some query containment solvers are available. Yet, there were no benchmarks to compare theses systems and foster their improvement. In order to experimentally assess implementation strengths and limitations, we provide a first SPARQL containment test benchmark. It has been designed with respect to both the capabilities of existing solvers and the study of typical queries. Some solvers support optional constructs and cycles, while other solvers support projection, union of conjunctive queries and RDF Schemas. No solver currently supports all these features or OWL entailment regimes. The study of query demographics on DBPedia logs shows that the vast majority of queries are acyclic and a significant part of them uses UNION or projection. We thus test available solvers on their domain of applicability on three different benchmark suites. These experiments show that (i) tested solutions are overall functionally correct, (ii) in spite of its complexity, SPARQL query containment is practicable for acyclic queries, (iii) state-of-the-art solvers are at an early stage both in terms of capability and implementation.


  1. 1.
    Angles, R., Gutierrez, C.: The expressive power of SPARQL. In: ISWC 2008. LNCS, vol. 5318, pp. 114–129. Springer, Heidelberg (2008)CrossRefGoogle Scholar
  2. 2.
    Bernstein, P., Chiu, D.: Using semi-joins to solve relational queries. Journal of the ACM 28(1), 25–40 (1981)MathSciNetCrossRefzbMATHGoogle Scholar
  3. 3.
    Bizer, C., Schultz, A.: Benchmarking the performance of storage systems that expose SPARQL endpoints. In: Proc. 4 th International Workshop on Scalable Semantic Web Knowledge Base Systems, SSWS (2008)Google Scholar
  4. 4.
    Bizer, C., Schultz, A.: The Berlin SPARQL benchmark. International Journal on Semantic Web and Information Systems 5(2), 1–24 (2009)CrossRefGoogle Scholar
  5. 5.
    Calvanese, D., De Giacomo, G., Lenzerini, M.: Conjunctive Query Containment and Answering under Description Logics Constraints. ACM Trans. on Computational Logic 9(3), 22.1–22.31 (2008)Google Scholar
  6. 6.
    Chandra, A.K., Merlin, P.M.: Optimal Implementation of Conjunctive Queries in Relational Data Bases. In: Proceedings of the Ninth Annual ACM Symposium on Theory of Computing, pp. 77–90. ACM (1977)Google Scholar
  7. 7.
    Chekol, M.W., Euzenat, J., Genevès, P., Layaïda, N.: SPARQL query containment under RDFS entailment regime. In: Proc. of the IJCAR, pp. 134–148 (2012)Google Scholar
  8. 8.
    Chekol, M.W., Euzenat, J., Genevès, P., Layaïda, N.: SPARQL query containment under SHI axioms. In: Proc. of the AAAI, pp. 10–16 (2012)Google Scholar
  9. 9.
    Chekuri, C., Rajaraman, A.: Conjunctive query containment revisited. In: Proc. of the CDT, pp. 56–70 (1997)Google Scholar
  10. 10.
    Genevès, P., Layaïda, N., Schmitt, A.: Efficient static analysis of XML paths and types. In: Proc. of the PLDI, pp. 342–351. ACM (2007)Google Scholar
  11. 11.
    Groppe, J., Groppe, S., Kolbaum, J.: Optimization of SPARQL by using core SPARQL. In: Proc.of the ICEIS, pp. 107–112 (2009)Google Scholar
  12. 12.
    Kozen, D.: Results on the propositional μ-calculus. Theor. Comp. Sci. 27, 333–354 (1983)MathSciNetCrossRefzbMATHGoogle Scholar
  13. 13.
    Letelier, A., Pérez, J., Pichler, R., Skritek, S.: Static analysis and optimization of semantic web queries. In: Proc. of the PODS, pp. 89–100. ACM (2012)Google Scholar
  14. 14.
    Morsey, M., Lehmann, J., Auer, S., Ngomo, A.-C.N.: DBpedia SPARQL benchmark – performance assessment with real queries on real data. In: Aroyo, L., Welty, C., Alani, H., Taylor, J., Bernstein, A., Kagal, L., Noy, N., Blomqvist, E. (eds.) ISWC 2011, Part I. LNCS, vol. 7031, pp. 454–469. Springer, Heidelberg (2011)CrossRefGoogle Scholar
  15. 15.
    Polleres, A.: From SPARQL to rules (and back). In: Proc. of the WWW Conference, pp. 787–796 (2007)Google Scholar
  16. 16.
    Prud’hommeaux, E., Seaborne, A.: SPARQL query language for RDF. W3C Recommendation (2008)Google Scholar
  17. 17.
    Schmidt, M., Hornung, T., Lausen, G., Pinkel, C.: SP2Bench: a SPARQL performance benchmark. In: Proc. of the ICDE, pp. 222–233 (2009)Google Scholar
  18. 18.
    Schmidt, M., Meier, M., Lausen, G.: Foundations of SPARQL query optimization. In: Proc. of the ICDT, pp. 4–33. ACM (2010)Google Scholar
  19. 19.
    Stocker, M., Seaborne, A., Bernstein, A., Kiefer, C., Reynolds, D.: SPARQL basic graph pattern optimization using selectivity estimation. In: Proc. of the WWW Conference, pp. 595–604 (2008)Google Scholar
  20. 20.
    Tanabe, Y., Takahashi, K., Yamamoto, M., Tozawa, A., Hagiya, M.: A decision procedure for the alternation-free two-way modal μ-calculus. In: Beckert, B. (ed.) TABLEAUX 2005. LNCS (LNAI), vol. 3702, pp. 277–291. Springer, Heidelberg (2005)CrossRefGoogle Scholar
  21. 21.
    Yannakakis, M.: Algorithms for acyclic database schemes. In: Proc. of the VLDB, pp. 82–94 (1981)Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2013

Authors and Affiliations

  • Melisachew Wudage Chekol
    • 1
    • 3
  • Jérôme Euzenat
    • 1
  • Pierre Genevès
    • 2
  • Nabil Layaïda
    • 1
  1. 1.INRIA and LIGFrance
  2. 2.CNRSFrance
  3. 3.LORIAFrance

Personalised recommendations