On containment of conjunctive queries with arithmetic comparisons

Foto Afrati, Chen Li, Prasenjit Mitra

Research output: Contribution to journalArticle

8 Citations (Scopus)

Abstract

We study the following problem: how to test if Q2 is contained in Q1, where Q1 and Q2 are conjunctive queries with arithmetic comparisons? This problem is fundamental in a large variety of database applications. Existing algorithms first normalize the queries, then test a logical implication using multiple containment mappings from Q 1 to Q2. We are interested in cases where the containment can be tested more efficiently. This work aims to (a) reduce the problem complexity from IIP2-completeness to NP-completeness in these cases; (b) utilize the advantages of the homomorphism property (i.e., the containment test is based on a single containment mapping) in applications such.as those of answering queries using views; and (c) observing that many real queries have the homomorphism property. The following are our results. (1) We show several cases where the normalization step is not needed, thus reducing the size of the queries and the number of containment mappings. (2) We develop an algorithm for checking various syntactic conditions on queries, under which the homomorphism property holds. (3) We further reduce the conditions of these classes using practical domain knowledge that is easily obtainable. (4) We conducted experiments on real queries, and show that most of the queries pass this test.

Original languageEnglish
Pages (from-to)459-476
Number of pages18
JournalLecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics)
Volume2992
Publication statusPublished - 2004
Externally publishedYes

Fingerprint

Query
Homomorphism
Databases
Syntactics
Normalize
NP-completeness
Domain Knowledge
Experiments
Normalization
Completeness
Experiment

ASJC Scopus subject areas

  • Computer Science(all)
  • Biochemistry, Genetics and Molecular Biology(all)
  • Theoretical Computer Science

Cite this

@article{78846766f4ff4961bf392d05e81ef1e0,
title = "On containment of conjunctive queries with arithmetic comparisons",
abstract = "We study the following problem: how to test if Q2 is contained in Q1, where Q1 and Q2 are conjunctive queries with arithmetic comparisons? This problem is fundamental in a large variety of database applications. Existing algorithms first normalize the queries, then test a logical implication using multiple containment mappings from Q 1 to Q2. We are interested in cases where the containment can be tested more efficiently. This work aims to (a) reduce the problem complexity from IIP2-completeness to NP-completeness in these cases; (b) utilize the advantages of the homomorphism property (i.e., the containment test is based on a single containment mapping) in applications such.as those of answering queries using views; and (c) observing that many real queries have the homomorphism property. The following are our results. (1) We show several cases where the normalization step is not needed, thus reducing the size of the queries and the number of containment mappings. (2) We develop an algorithm for checking various syntactic conditions on queries, under which the homomorphism property holds. (3) We further reduce the conditions of these classes using practical domain knowledge that is easily obtainable. (4) We conducted experiments on real queries, and show that most of the queries pass this test.",
author = "Foto Afrati and Chen Li and Prasenjit Mitra",
year = "2004",
language = "English",
volume = "2992",
pages = "459--476",
journal = "Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics)",
issn = "0302-9743",
publisher = "Springer Verlag",

}

TY - JOUR

T1 - On containment of conjunctive queries with arithmetic comparisons

AU - Afrati, Foto

AU - Li, Chen

AU - Mitra, Prasenjit

PY - 2004

Y1 - 2004

N2 - We study the following problem: how to test if Q2 is contained in Q1, where Q1 and Q2 are conjunctive queries with arithmetic comparisons? This problem is fundamental in a large variety of database applications. Existing algorithms first normalize the queries, then test a logical implication using multiple containment mappings from Q 1 to Q2. We are interested in cases where the containment can be tested more efficiently. This work aims to (a) reduce the problem complexity from IIP2-completeness to NP-completeness in these cases; (b) utilize the advantages of the homomorphism property (i.e., the containment test is based on a single containment mapping) in applications such.as those of answering queries using views; and (c) observing that many real queries have the homomorphism property. The following are our results. (1) We show several cases where the normalization step is not needed, thus reducing the size of the queries and the number of containment mappings. (2) We develop an algorithm for checking various syntactic conditions on queries, under which the homomorphism property holds. (3) We further reduce the conditions of these classes using practical domain knowledge that is easily obtainable. (4) We conducted experiments on real queries, and show that most of the queries pass this test.

AB - We study the following problem: how to test if Q2 is contained in Q1, where Q1 and Q2 are conjunctive queries with arithmetic comparisons? This problem is fundamental in a large variety of database applications. Existing algorithms first normalize the queries, then test a logical implication using multiple containment mappings from Q 1 to Q2. We are interested in cases where the containment can be tested more efficiently. This work aims to (a) reduce the problem complexity from IIP2-completeness to NP-completeness in these cases; (b) utilize the advantages of the homomorphism property (i.e., the containment test is based on a single containment mapping) in applications such.as those of answering queries using views; and (c) observing that many real queries have the homomorphism property. The following are our results. (1) We show several cases where the normalization step is not needed, thus reducing the size of the queries and the number of containment mappings. (2) We develop an algorithm for checking various syntactic conditions on queries, under which the homomorphism property holds. (3) We further reduce the conditions of these classes using practical domain knowledge that is easily obtainable. (4) We conducted experiments on real queries, and show that most of the queries pass this test.

UR - http://www.scopus.com/inward/record.url?scp=35048867454&partnerID=8YFLogxK

UR - http://www.scopus.com/inward/citedby.url?scp=35048867454&partnerID=8YFLogxK

M3 - Article

VL - 2992

SP - 459

EP - 476

JO - Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics)

JF - Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics)

SN - 0302-9743

ER -