Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
research-article
Public Access

Consistent Query Answering for Self-Join-Free Conjunctive Queries Under Primary Key Constraints

Published: 01 June 2017 Publication History

Abstract

A relational database is said to be uncertain if primary key constraints can possibly be violated. A repair (or possible world) of an uncertain database is obtained by selecting a maximal number of tuples without ever selecting two distinct tuples with the same primary key value. For any Boolean query q, CERTAINTY(q) is the problem that takes an uncertain database db as input and asks whether q is true in every repair of db. The complexity of this problem has been particularly studied for q ranging over the class of self-join-free Boolean conjunctive queries. A research challenge is to determine, given q, whether CERTAINTY(q) belongs to complexity classes FO, P, or coNP-complete.
In this article, we combine existing techniques for studying this complexity classification task. We show that, for any self-join-free Boolean conjunctive query q, it can be decided whether or not CERTAINTY(q) is in FO. We additionally show how to construct a single SQL query for solving CERTAINTY(q) if it is in FO. Further, for any self-join-free Boolean conjunctive query q, CERTAINTY(q) is either in P or coNP-complete and the complexity dichotomy is effective. This settles a research question that has been open for 10 years.

Supplementary Material

a9-koutris-apndx.pdf (koutris.zip)
Supplemental movie, appendix, image and software files for, Consistent Query Answering for Self-Join-Free Conjunctive Queries Under Primary Key Constraints

References

[1]
Serge Abiteboul, Richard Hull, and Victor Vianu. 1995. Foundations of Databases. Addison-Wesley, New York, NY.
[2]
Marcelo Arenas, Leopoldo E. Bertossi, and Jan Chomicki. 1999. Consistent query answers in inconsistent databases. In Proceedings of the 18th ACM SIGACT-SIGMOD-SIGART Symposium on Principles of Database Systems, May 31 - June 2, 1999, Philadelphia, Pennsylvania, Victor Vianu and Christos H. Papadimitriou (Eds.). ACM Press, 68--79.
[3]
Marcelo Arenas, Leopoldo E. Bertossi, and Jan Chomicki. 2003a. Answer sets for consistent query answering in inconsistent databases. Theory and Practice of Logic Programming 3, 4--5, 393--424.
[4]
Marcelo Arenas, Leopoldo E. Bertossi, Jan Chomicki, Xin He, Vijay Raghavan, and Jeremy P. Spinrad. 2003b. Scalar aggregation in inconsistent databases. Theoretical Computer Science 296, 3, 405--434.
[5]
Bengt Aspvall, Michael F. Plass, and Robert Endre Tarjan. 1979. A linear-time algorithm for testing the truth of certain quantified Boolean formulas. Information Processing Letters 8, 3, 121--123.
[6]
Leopoldo E. Bertossi. 2011. Database Repairing and Consistent Query Answering. Morgan 8 Claypool Publishers, San Francisco, CA.
[7]
Meghyn Bienvenu, Camille Bourgaux, and François Goasdoué. 2016. Explaining inconsistency-tolerant query answering over description logic knowledge bases. In Proceedings of the 30th AAAI Conference on Artificial Intelligence, February 12-17, 2016, Phoenix, AZ, Dale Schuurmans and Michael P. Wellman (Eds.). AAAI Press, 900--906. http://www.aaai.org/ocs/index.php/AAAI/AAAI16/paper/view/12025
[8]
Andrei A. Bulatov. 2011. Complexity of conservative constraint satisfaction problems. ACM Transactions on Computational Logic 12, 4, 24:1--24:66.
[9]
Jan Chomicki and Jerzy Marcinkowski. 2005. Minimal-change integrity maintenance using tuple deletions. Information and Computation 197, 1--2, 90--121.
[10]
Jan Chomicki, Jerzy Marcinkowski, and Slawomir Staworko. 2004. Hippo: A system for computing consistent answers to a class of SQL queries. In EDBT (Lecture Notes in Computer Science), Elisa Bertino, Stavros Christodoulakis, Dimitris Plexousakis, Vassilis Christophides, Manolis Koubarakis, Klemens Böhm, and Elena Ferrari (Eds.), Vol. 2992. Springer, Berlin, 841--844.
[11]
Stephen A. Cook and Pierre McKenzie. 1987. Problems complete for deterministic logarithmic space. Journal of Algorithms 8, 3, 385--394.
[12]
Alexandre Decan, Fabian Pijcke, and Jef Wijsen. 2012. Certain conjunctive query answering in SQL. In Proceedings of the Scalable Uncertainty Management - 6th International Conference, SUM 2012, Marburg, Germany, September 17-19, 2012 (Lecture Notes in Computer Science), Eyke Hüllermeier, Sebastian Link, Thomas Fober, and Bernhard Seeger (Eds.), Vol. 7520. Springer, Berlin, 154--167.
[13]
Ronald Fagin. 1983. Degrees of acyclicity for hypergraphs and relational database schemes. Journal of the ACM 30, 3, 514--550.
[14]
Ronald Fagin, Benny Kimelfeld, and Phokion G. Kolaitis. 2015. Dichotomies in the complexity of preferred repairs, In Tova Milo and Diego Calvanese (Eds.). Proceedings of the 34th ACM Symposium on Principles of Database Systems, PODS 2015, Melbourne, Victoria, Australia, May 31 - June 4, 2015. ACM. 3--15.
[15]
Gaëlle Fontaine. 2013. Why is it hard to obtain a dichotomy for consistent query answering? In 28th Annual ACM/IEEE Symposium on Logic in Computer Science, LICS 2013, New Orleans, LA, USA, June 25-28, 2013. IEEE Computer Society, 550--559.
[16]
Ariel Fuxman, Elham Fazli, and Renée J. Miller. 2005. ConQuer: Efficient management of inconsistent databases. In Proceedings of the ACM SIGMOD International Conference on Management of Data, Baltimore, Maryland, USA, June 14-16, 2005, Fatma Özcan (Ed.). ACM, 155--166.
[17]
Ariel Fuxman and Renée J. Miller. 2005. First-order query rewriting for inconsistent databases. In Proceedings of the 10th International Conference on Database Theory (ICDT’05), Edinburgh, UK, January 5-7, 2005, (Lecture Notes in Computer Science), Thomas Eiter and Leonid Libkin (Eds.), Vol. 3363. Springer, Berlin, 337--351.
[18]
Ariel Fuxman and Renée J. Miller. 2007. First-order query rewriting for inconsistent databases. Journal of Computer and System Sciences 73, 4, 610--635.
[19]
Gianluigi Greco, Sergio Greco, and Ester Zumpano. 2003. A logical framework for querying and repairing inconsistent databases. IEEE Transactions on Knowl.edge and Data Engineering 15, 6, 1389--1408.
[20]
Neil Immerman. 1999. Descriptive Complexity. Springer.
[21]
Phokion G. Kolaitis and Enela Pema. 2012. A dichotomy in the complexity of consistent query answering for queries with two atoms. Information Processing Letters 112, 3, 77--85.
[22]
Phokion G. Kolaitis, Enela Pema, and Wang-Chiew Tan. 2013. Efficient querying of inconsistent databases with binary integer programming. Proceedings of the PLVD Endowment 6, 6, 397--408. http://www.vldb.org/pvldb/vol6/p397-tan.pdf.
[23]
Paraschos Koutris and Dan Suciu. 2014. A dichotomy on the complexity of consistent query answering for atoms with simple keys. In Nicole Schweikardt, Vassilis Christophides, and Vincent Leroy (Eds.). 2014. Proceedings of the 17th International Conference on Database Theory (ICDT’14), Athens, Greece, March 24-28, 2014, 165--176.
[24]
Paraschos Koutris and Jef Wijsen. 2015. The data complexity of consistent query answering for self-join-free conjunctive queries under primary key constraints. In Tova Milo and Diego Calvanese (Eds.). 2015. Proceedings of the 34th ACM Symposium on Principles of Database Systems, PODS 2015, Melbourne, Victoria, Australia, May 31 - June 4, 2015. ACM. 17--29.
[25]
Paraschos Koutris and Jef Wijsen. 2016. Consistent query answering for primary keys. SIGMOD Record 45, 1, 15--22.
[26]
Richard E. Ladner. 1975. On the structure of polynomial time reducibility. Journal of the ACM 22, 1, 155--171.
[27]
Domenico Lembo, Maurizio Lenzerini, Riccardo Rosati, Marco Ruzzi, and Domenico Fabio Savo. 2015. Inconsistency-tolerant query answering in ontology-based data access. Journal of Web Semantics 33, 3--29.
[28]
Leonid Libkin. 2004. Elements of Finite Model Theory. Springer.
[29]
Thomas Lukasiewicz, Maria Vanina Martinez, Andreas Pieris, and Gerardo I. Simari. 2015. From classical to consistent query answering under existential rules. In Proceedings of the 29th AAAI Conference on Artificial Intelligence, January 25-30, 2015, Austin, TX. Blai Bonet and Sven Koenig (Eds.). AAAI Press, 1546--1552. http://www.aaai.org/ocs/index.php/AAAI/AAAI15/paper/view/9817
[30]
Mónica Caniupán Marileo and Leopoldo E. Bertossi. 2010. The consistency extractor system: Answer set programs for consistent query answering in databases. Data and Knowledge Engineering 69, 6, 545--572.
[31]
Maria Vanina Martinez, Francesco Parisi, Andrea Pugliese, Gerardo I. Simari, and V. S. Subrahmanian. 2014. Policy-based inconsistency management in relational databases. International Journal of Approximate Reasoning 55, 2, 501--528.
[32]
Dany Maslowski and Jef Wijsen. 2013. A dichotomy in the complexity of counting database repairs. Journal of Computer and System Sciences 79, 6, 958--983.
[33]
Dany Maslowski and Jef Wijsen. 2014. Counting database repairs that satisfy conjunctive queries with self-joins, In Nicole Schweikardt, Vassilis Christophides, and Vincent Leroy (Eds.). 2014. Proceedings of the 17th International Conference on Database Theory (ICDT’14), Athens, Greece, March 24-28, 2014. 155--164.
[34]
Tova Milo and Diego Calvanese (Eds.). 2015. Proceedings of the 34th ACM Symposium on Principles of Database Systems (PODS’15), Melbourne, Victoria, Australia, May 31 - June 4, 2015. ACM. http://dl.acm.org/citation.cfm?id=2745754
[35]
George J. Minty. 1980. On maximal independent sets of vertices in claw-free graphs. Journal of Combinatorial Theory, Series B 28, 3, 284--304.
[36]
Nicole Schweikardt, Vassilis Christophides, and Vincent Leroy (Eds.). 2014. Proceedings of the 17th International Conference on Database Theory (ICDT’14), Athens, Greece, March 24-28, 2014. Open-Proceedings.org. http://openproceedings.org/edbticdt2014/ICDT_toc.html.
[37]
Slawek Staworko, Jan Chomicki, and Jerzy Marcinkowski. 2012. Prioritized repairing and consistent query answering in relational databases. Annals of Mathematics and Artificial Intelligence 64, 2--3, 209--246.
[38]
Wang-Chiew Tan. 2016. Technical perspective: Attacking the problem of consistent query answering. SIGMOD Record 45, 1, 14.
[39]
Jeffrey D. Ullman. 1988. Principles of Database and Knowledge-Base Systems, Volume I. Computer Science Press, Rockville, MD.
[40]
Jef Wijsen. 2009. On the consistent rewriting of conjunctive queries under primary key constraints. Information Systems 34, 7, 578--601.
[41]
Jef Wijsen. 2010a. On the first-order expressibility of computing certain answers to conjunctive queries over uncertain databases. In Proceedings of the 29th ACM SIGMOD-SIGACT-SIGART Symposium on Principles of Database Systems (PODS’10), June 6-11, 2010, Indianapolis, IN, Jan Paredaens and Dirk Van Gucht (Eds.). ACM, 179--190.
[42]
Jef Wijsen. 2010b. A remark on the complexity of consistent conjunctive query answering under primary key violations. Information Processing Letters 110, 21, 950--955.
[43]
Jef Wijsen. 2012. Certain conjunctive query answering in first-order logic. ACM Transactions on Database Systems 37, 2, 9:1--9:35.
[44]
Jef Wijsen. 2013. Charting the tractability frontier of certain conjunctive query answering. In Proceedings of the 32nd ACM SIGMOD-SIGACT-SIGART Symposium on Principles of Database Systems, (PODS’13), New York, NY, June 22-27, 2013, Richard Hull and Wenfei Fan (Eds.). ACM, 189--200.
[45]
Jef Wijsen. 2014. A survey of the data complexity of consistent query answering under key constraints. In Proceedings of Foundations of Information and Knowledge Systems - 8th International Symposium (FoIKS’14), Bordeaux, France, March 3-7, 2014. (Lecture Notes in Computer Science), Christoph Beierle and Carlo Meghini (Eds.), Vol. 8367. Springer, Berlin, 62--78.

Cited By

View all
  • (2024)Consistent Query Answering for Primary Keys on Rooted Tree QueriesProceedings of the ACM on Management of Data10.1145/36511392:2(1-26)Online publication date: 14-May-2024
  • (2024)A Dichotomy in the Complexity of Consistent Query Answering for Two Atom Queries With Self-JoinProceedings of the ACM on Management of Data10.1145/36511372:2(1-15)Online publication date: 14-May-2024
  • (2024)A Unifying Framework for Incompleteness, Inconsistency, and Uncertainty in DatabasesCommunications of the ACM10.1145/362471767:3(74-83)Online publication date: 22-Feb-2024
  • Show More Cited By

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Transactions on Database Systems
ACM Transactions on Database Systems  Volume 42, Issue 2
Invited Paper from SIGMOD 2015, Invited Paper from PODS 2015 and Regular Papers
June 2017
251 pages
ISSN:0362-5915
EISSN:1557-4644
DOI:10.1145/3086510
Issue’s Table of Contents
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 01 June 2017
Accepted: 01 March 2017
Revised: 01 September 2016
Received: 01 December 2015
Published in TODS Volume 42, Issue 2

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. Attack graph
  2. complexity dichotomy
  3. conjunctive queries
  4. consistent query answering
  5. primary keys

Qualifiers

  • Research-article
  • Research
  • Refereed

Funding Sources

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)119
  • Downloads (Last 6 weeks)17
Reflects downloads up to 30 Aug 2024

Other Metrics

Citations

Cited By

View all
  • (2024)Consistent Query Answering for Primary Keys on Rooted Tree QueriesProceedings of the ACM on Management of Data10.1145/36511392:2(1-26)Online publication date: 14-May-2024
  • (2024)A Dichotomy in the Complexity of Consistent Query Answering for Two Atom Queries With Self-JoinProceedings of the ACM on Management of Data10.1145/36511372:2(1-15)Online publication date: 14-May-2024
  • (2024)A Unifying Framework for Incompleteness, Inconsistency, and Uncertainty in DatabasesCommunications of the ACM10.1145/362471767:3(74-83)Online publication date: 22-Feb-2024
  • (2023)LinCQA: Faster Consistent Query Answering with Linear Time GuaranteesProceedings of the ACM on Management of Data10.1145/35887181:1(1-25)Online publication date: 30-May-2023
  • (2022)A Dichotomy in Consistent Query Answering for Primary Keys and Unary Foreign KeysProceedings of the 41st ACM SIGMOD-SIGACT-SIGAI Symposium on Principles of Database Systems10.1145/3517804.3524157(437-449)Online publication date: 12-Jun-2022
  • (2022)Consistent Answers of Aggregation Queries via SAT2022 IEEE 38th International Conference on Data Engineering (ICDE)10.1109/ICDE53745.2022.00074(924-937)Online publication date: May-2022
  • (2022)Approximation and inapproximability results on computing optimal repairsThe VLDB Journal — The International Journal on Very Large Data Bases10.1007/s00778-022-00738-032:1(173-197)Online publication date: 12-Apr-2022
  • (2021)Consistent Query Answering for Primary Keys on Path QueriesProceedings of the 40th ACM SIGMOD-SIGACT-SIGAI Symposium on Principles of Database Systems10.1145/3452021.3458334(215-232)Online publication date: 20-Jun-2021
  • (2021)Properties of Inconsistency Measures for DatabasesProceedings of the 2021 International Conference on Management of Data10.1145/3448016.3457310(1182-1194)Online publication date: 9-Jun-2021
  • (2021)CAvSAT: Answering Aggregation Queries over Inconsistent Databases via SAT SolvingProceedings of the 2021 International Conference on Management of Data10.1145/3448016.3452749(2701-2705)Online publication date: 9-Jun-2021
  • Show More Cited By

View Options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Get Access

Login options

Full Access

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media