The current standard query language SQL requires users to know how data is normalized and stored in a database schema to compose queries. One of the major challenges in generating these queries is the identification of joins to connect attributes located in different relations. Constructing these joins in SQL or through a graphical query interface is tedious, error-prone, and not intuitive to casual users. Any new query language should maintain the expressiveness of SQL without requiring schema knowledge or an additional model.
The structure of a normalized database inherently supports the automatic completion of an underspecified SQL query to the intended SQL query through cooperative disambiguation. The existing languages pursuing logical data independence are either unable to match the expressiveness of SQL or they require schema knowledge to express the full range of queries. A new Schema-Free query system is developed to support the automatic completion of an SQL query without the full specification of joins and tables. A new algorithm efficiently constructs all maximal sets of lossless joins in a schema an order of magnitude faster than previous methods. The query system uses a new query language allowing under-specification of SQL queries to remove the burden of schema knowledge from the user while supporting the full scope of SQL queries.
Queries with multiple interpretations are disambiguated through three different approaches. The underspecified SQL query is completed to either a list of fully specified SQL queries or semantically disambiguated queries through roles specified for each attribute. These interpretation lists are ordered by the number of joins with all lossless interpretations listed prior to lossy interpretations. The final approach resolves the ambiguity through a series of questions dictated by the schema ambiguity involved in the query interpretations to identify the final query. Overall, query inference is a practical tool to simplify the extraction of information in a database.
Index Terms
- Schema-free sql: providing freedom from the schema knowledge required for sql querying
Recommendations
Schema-free SQL
SIGMOD '14: Proceedings of the 2014 ACM SIGMOD International Conference on Management of DataQuerying data in relational databases is often challenging since SQL requires its users to know the exact schema of the database, the roles of various entities in a query, and the precise join paths to be followed. On the other hand, keyword search is ...