Wed 7 Nov 2018 18:22 - 18:24 at Georgian - Poster & SRC
The ability to reason about relational queries plays an important role across various types of database applications, such as test data generation, query equivalence checking, and computer-assisted query authoring tools. Unfortunately, scaling up query reasoning can be challenging as relational tables contains tuples of different types, and relational query languages such as SQL can introduce complex interactions among tuples.In this paper, we propose a new space refinement algorithm to make reasoning of relational queries efficient.Our refinement procedure is independent of the specific database application, and exploits the structural features of queries along with the provenance of tuples in the output table to soundly refine the space of tables that such applications need to consider. As a result of our refinement, the application only needs to consider a small fragment of the original space of tables in order to complete the reasoning process. We have implemented our refinement algorithm, and evaluated it using three different reasoning tasks for SQL:bounded equivalence checking of queries, test generation for applications that manipulate relational data, and concolic testing of database applications. Using real world benchmarks, our study shows that our refinement algorithm can provide significant speedup for reasoning a large class of challenging SQL queries (e.g., queries with aggregations), and can improve the performance of applications that perform relational query reasoning by up to 100×as compared to the original.