Design and Implementation of a Knowledge-Based Query Processor

This paper deals with query processing using semantic knowledge in relational databases. The Select-Project-Join (SPJ) conjunctive class of queries are dealt with in this paper. We propose to optimize highly repetitive queries by using semantic transformations in addition to syntactic transformations. Thus, we generate a set of pre-optimized queries. This set contains queries that are semantically equivalent to, syntactically different from, and more efficient to process than the user queries that we started with. The issues we address in this paper are: how to map a user query to a query that is in the set of pre-optimized and already optimized queries, how to search efficiently through the set of pre-optimized queries and set of semantic rules, and how to incorporate new queries to the set of pre-optimized queries, so that the number of queries that can be optimized using this method increases with the passage of time. Furthermore, we suggest some ideas of handling queries that do not have any semantically equivalent counterpart in the set of pre-optimized queries. We have tested the performance of the proposed method. An algorithm for mapping is implemented in Prolog. A database schema is implemented in the INGRES database management system. We have adopted a database schema that is widely used for measuring performance in the semantic query optimization literature.